<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><link rel="stylesheet" type="text/css" href="style.css" /><script type="text/javascript" src="highlight.js"></script></head><body><pre><span id="local-6989586621681005848"><span id="local-6989586621681005849"><span id="local-6989586621681005850"><span id="local-6989586621681005851"></span></span></span></span><span class="hs-pragma">{-# LANGUAGE CPP, GeneralizedNewtypeDeriving #-}</span><span>
</span><span id="line-2"></span><span class="hs-pragma">{-# LANGUAGE LambdaCase #-}</span><span>
</span><span id="line-3"></span><span>
</span><span id="line-4"></span><span class="hs-comment">--------------------------------------------------------------------------------</span><span>
</span><span id="line-5"></span><span class="hs-comment">-- | The LLVM Type System.</span><span>
</span><span id="line-6"></span><span class="hs-comment">--</span><span>
</span><span id="line-7"></span><span>
</span><span id="line-8"></span><span class="hs-keyword">module</span><span> </span><span class="hs-identifier">GHC.Llvm.Types</span><span> </span><span class="hs-keyword">where</span><span class="hs-cpp">

#include &quot;HsVersions.h&quot;
</span><span>
</span><span id="line-12"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Prelude.html"><span class="hs-identifier">GHC.Prelude</span></a></span><span>
</span><span id="line-13"></span><span>
</span><span id="line-14"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Data.Char.html#"><span class="hs-identifier">Data.Char</span></a></span><span>
</span><span id="line-15"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/Numeric.html#"><span class="hs-identifier">Numeric</span></a></span><span>
</span><span id="line-16"></span><span>
</span><span id="line-17"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../ghc-boot/src/GHC.Platform.html#"><span class="hs-identifier">GHC.Platform</span></a></span><span>
</span><span id="line-18"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Driver.Session.html"><span class="hs-identifier">GHC.Driver.Session</span></a></span><span>
</span><span id="line-19"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Data.FastString.html"><span class="hs-identifier">GHC.Data.FastString</span></a></span><span>
</span><span id="line-20"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Utils.Outputable.html"><span class="hs-identifier">GHC.Utils.Outputable</span></a></span><span>
</span><span id="line-21"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Types.Unique.html"><span class="hs-identifier">GHC.Types.Unique</span></a></span><span>
</span><span id="line-22"></span><span>
</span><span id="line-23"></span><span class="hs-comment">-- from NCG</span><span>
</span><span id="line-24"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.CmmToAsm.Ppr.html"><span class="hs-identifier">GHC.CmmToAsm.Ppr</span></a></span><span>
</span><span id="line-25"></span><span>
</span><span id="line-26"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="../../base/src/GHC.Float.html#"><span class="hs-identifier">GHC.Float</span></a></span><span>
</span><span id="line-27"></span><span>
</span><span id="line-28"></span><span class="hs-comment">-- -----------------------------------------------------------------------------</span><span>
</span><span id="line-29"></span><span class="hs-comment">-- * LLVM Basic Types and Variables</span><span>
</span><span id="line-30"></span><span class="hs-comment">--</span><span>
</span><span id="line-31"></span><span>
</span><span id="line-32"></span><span class="hs-comment">-- | A global mutable variable. Maybe defined or external</span><span>
</span><span id="line-33"></span><span class="hs-keyword">data</span><span> </span><span id="LMGlobal"><span class="annot"><a href="GHC.Llvm.Types.html#LMGlobal"><span class="hs-identifier hs-var">LMGlobal</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="LMGlobal"><span class="annot"><a href="GHC.Llvm.Types.html#LMGlobal"><span class="hs-identifier hs-var">LMGlobal</span></a></span></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-34"></span><span>  </span><span id="getGlobalVar"><span class="annot"><span class="annottext">LMGlobal -&gt; LlvmVar
</span><a href="GHC.Llvm.Types.html#getGlobalVar"><span class="hs-identifier hs-var hs-var">getGlobalVar</span></a></span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmVar"><span class="hs-identifier hs-type">LlvmVar</span></a></span><span class="hs-special">,</span><span>          </span><span class="hs-comment">-- ^ Returns the variable of the 'LMGlobal'</span><span>
</span><span id="line-35"></span><span>  </span><span id="getGlobalValue"><span class="annot"><span class="annottext">LMGlobal -&gt; Maybe LlvmStatic
</span><a href="GHC.Llvm.Types.html#getGlobalValue"><span class="hs-identifier hs-var hs-var">getGlobalValue</span></a></span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span> </span><span class="hs-comment">-- ^ Return the value of the 'LMGlobal'</span><span>
</span><span id="line-36"></span><span>  </span><span class="hs-special">}</span><span>
</span><span id="line-37"></span><span>
</span><span id="line-38"></span><span class="hs-comment">-- | A String in LLVM</span><span>
</span><span id="line-39"></span><span class="hs-keyword">type</span><span> </span><span id="LMString"><span class="annot"><a href="GHC.Llvm.Types.html#LMString"><span class="hs-identifier hs-var">LMString</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><a href="GHC.Data.FastString.html#FastString"><span class="hs-identifier hs-type">FastString</span></a></span><span>
</span><span id="line-40"></span><span>
</span><span id="line-41"></span><span class="hs-comment">-- | A type alias</span><span>
</span><span id="line-42"></span><span class="hs-keyword">type</span><span> </span><span id="LlvmAlias"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmAlias"><span class="hs-identifier hs-var">LlvmAlias</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMString"><span class="hs-identifier hs-type">LMString</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-43"></span><span>
</span><span id="line-44"></span><span class="hs-comment">-- | Llvm Types</span><span>
</span><span id="line-45"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmType"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-var">LlvmType</span></a></span></span><span>
</span><span id="line-46"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="LMInt"><span class="annot"><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-var">LMInt</span></a></span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span>             </span><span class="hs-comment">-- ^ An integer with a given width in bits.</span><span>
</span><span id="line-47"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMFloat"><span class="annot"><a href="GHC.Llvm.Types.html#LMFloat"><span class="hs-identifier hs-var">LMFloat</span></a></span></span><span>               </span><span class="hs-comment">-- ^ 32 bit floating point</span><span>
</span><span id="line-48"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMDouble"><span class="annot"><a href="GHC.Llvm.Types.html#LMDouble"><span class="hs-identifier hs-var">LMDouble</span></a></span></span><span>              </span><span class="hs-comment">-- ^ 64 bit floating point</span><span>
</span><span id="line-49"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMFloat80"><span class="annot"><a href="GHC.Llvm.Types.html#LMFloat80"><span class="hs-identifier hs-var">LMFloat80</span></a></span></span><span>             </span><span class="hs-comment">-- ^ 80 bit (x86 only) floating point</span><span>
</span><span id="line-50"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMFloat128"><span class="annot"><a href="GHC.Llvm.Types.html#LMFloat128"><span class="hs-identifier hs-var">LMFloat128</span></a></span></span><span>            </span><span class="hs-comment">-- ^ 128 bit floating point</span><span>
</span><span id="line-51"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMPointer"><span class="annot"><a href="GHC.Llvm.Types.html#LMPointer"><span class="hs-identifier hs-var">LMPointer</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>    </span><span class="hs-comment">-- ^ A pointer to a 'LlvmType'</span><span>
</span><span id="line-52"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMArray"><span class="annot"><a href="GHC.Llvm.Types.html#LMArray"><span class="hs-identifier hs-var">LMArray</span></a></span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>  </span><span class="hs-comment">-- ^ An array of 'LlvmType'</span><span>
</span><span id="line-53"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMVector"><span class="annot"><a href="GHC.Llvm.Types.html#LMVector"><span class="hs-identifier hs-var">LMVector</span></a></span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-comment">-- ^ A vector of 'LlvmType'</span><span>
</span><span id="line-54"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMLabel"><span class="annot"><a href="GHC.Llvm.Types.html#LMLabel"><span class="hs-identifier hs-var">LMLabel</span></a></span></span><span>               </span><span class="hs-comment">-- ^ A 'LlvmVar' can represent a label (address)</span><span>
</span><span id="line-55"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMVoid"><span class="annot"><a href="GHC.Llvm.Types.html#LMVoid"><span class="hs-identifier hs-var">LMVoid</span></a></span></span><span>                </span><span class="hs-comment">-- ^ Void type</span><span>
</span><span id="line-56"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMStruct"><span class="annot"><a href="GHC.Llvm.Types.html#LMStruct"><span class="hs-identifier hs-var">LMStruct</span></a></span></span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span class="hs-special">]</span><span>   </span><span class="hs-comment">-- ^ Packed structure type</span><span>
</span><span id="line-57"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMStructU"><span class="annot"><a href="GHC.Llvm.Types.html#LMStructU"><span class="hs-identifier hs-var">LMStructU</span></a></span></span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span class="hs-special">]</span><span>  </span><span class="hs-comment">-- ^ Unpacked structure type</span><span>
</span><span id="line-58"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMAlias"><span class="annot"><a href="GHC.Llvm.Types.html#LMAlias"><span class="hs-identifier hs-var">LMAlias</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmAlias"><span class="hs-identifier hs-type">LlvmAlias</span></a></span><span>     </span><span class="hs-comment">-- ^ A type alias</span><span>
</span><span id="line-59"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMMetadata"><span class="annot"><a href="GHC.Llvm.Types.html#LMMetadata"><span class="hs-identifier hs-var">LMMetadata</span></a></span></span><span>            </span><span class="hs-comment">-- ^ LLVM Metadata</span><span>
</span><span id="line-60"></span><span>
</span><span id="line-61"></span><span>  </span><span class="hs-comment">-- | Function type, used to create pointers to functions</span><span>
</span><span id="line-62"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMFunction"><span class="annot"><a href="GHC.Llvm.Types.html#LMFunction"><span class="hs-identifier hs-var">LMFunction</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmFunctionDecl"><span class="hs-identifier hs-type">LlvmFunctionDecl</span></a></span><span>
</span><span id="line-63"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005768"><span id="local-6989586621681005784"><span class="annot"><span class="annottext">LlvmType -&gt; LlvmType -&gt; Bool
(LlvmType -&gt; LlvmType -&gt; Bool)
-&gt; (LlvmType -&gt; LlvmType -&gt; Bool) -&gt; Eq LlvmType
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmType -&gt; LlvmType -&gt; Bool
$c/= :: LlvmType -&gt; LlvmType -&gt; Bool
== :: LlvmType -&gt; LlvmType -&gt; Bool
$c== :: LlvmType -&gt; LlvmType -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-64"></span><span>
</span><span id="line-65"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621681005763"><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-66"></span><span>  </span><span id="local-6989586621681005761"><span class="annot"><span class="annottext">ppr :: LlvmType -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var hs-var hs-var hs-var">ppr</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppType"><span class="hs-identifier hs-var">ppType</span></a></span><span>
</span><span id="line-67"></span><span>
</span><span id="line-68"></span><span class="annot"><a href="GHC.Llvm.Types.html#ppType"><span class="hs-identifier hs-type">ppType</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Utils.Outputable.html#SDoc"><span class="hs-identifier hs-type">SDoc</span></a></span><span>
</span><span id="line-69"></span><span id="ppType"><span class="annot"><span class="annottext">ppType :: LlvmType -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppType"><span class="hs-identifier hs-var hs-var">ppType</span></a></span></span><span> </span><span id="local-6989586621681005758"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005758"><span class="hs-identifier hs-var">t</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005758"><span class="hs-identifier hs-var">t</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-70"></span><span>  </span><span class="annot"><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-type">LMInt</span></a></span><span> </span><span id="local-6989586621681005757"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005757"><span class="hs-identifier hs-var">size</span></a></span></span><span>     </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Char -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#char"><span class="hs-identifier hs-var">char</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'i'</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005757"><span class="hs-identifier hs-var">size</span></a></span><span>
</span><span id="line-71"></span><span>  </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMFloat"><span class="hs-identifier hs-var">LMFloat</span></a></span><span>        </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;float&quot;</span></span><span>
</span><span id="line-72"></span><span>  </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMDouble"><span class="hs-identifier hs-var">LMDouble</span></a></span><span>       </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;double&quot;</span></span><span>
</span><span id="line-73"></span><span>  </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMFloat80"><span class="hs-identifier hs-var">LMFloat80</span></a></span><span>      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;x86_fp80&quot;</span></span><span>
</span><span id="line-74"></span><span>  </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMFloat128"><span class="hs-identifier hs-var">LMFloat128</span></a></span><span>     </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;fp128&quot;</span></span><span>
</span><span id="line-75"></span><span>  </span><span class="annot"><a href="GHC.Llvm.Types.html#LMPointer"><span class="hs-identifier hs-type">LMPointer</span></a></span><span> </span><span id="local-6989586621681005753"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005753"><span class="hs-identifier hs-var">x</span></a></span></span><span>    </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005753"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#char"><span class="hs-identifier hs-var">char</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'*'</span></span><span>
</span><span id="line-76"></span><span>  </span><span class="annot"><a href="GHC.Llvm.Types.html#LMArray"><span class="hs-identifier hs-type">LMArray</span></a></span><span> </span><span id="local-6989586621681005752"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005752"><span class="hs-identifier hs-var">nr</span></a></span></span><span> </span><span id="local-6989586621681005751"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005751"><span class="hs-identifier hs-var">tp</span></a></span></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Char -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#char"><span class="hs-identifier hs-var">char</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'['</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005752"><span class="hs-identifier hs-var">nr</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot; x &quot;</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005751"><span class="hs-identifier hs-var">tp</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#char"><span class="hs-identifier hs-var">char</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">']'</span></span><span>
</span><span id="line-77"></span><span>  </span><span class="annot"><a href="GHC.Llvm.Types.html#LMVector"><span class="hs-identifier hs-type">LMVector</span></a></span><span> </span><span id="local-6989586621681005750"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005750"><span class="hs-identifier hs-var">nr</span></a></span></span><span> </span><span id="local-6989586621681005749"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005749"><span class="hs-identifier hs-var">tp</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Char -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#char"><span class="hs-identifier hs-var">char</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'&lt;'</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005750"><span class="hs-identifier hs-var">nr</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot; x &quot;</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005749"><span class="hs-identifier hs-var">tp</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#char"><span class="hs-identifier hs-var">char</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'&gt;'</span></span><span>
</span><span id="line-78"></span><span>  </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMLabel"><span class="hs-identifier hs-var">LMLabel</span></a></span><span>        </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;label&quot;</span></span><span>
</span><span id="line-79"></span><span>  </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMVoid"><span class="hs-identifier hs-var">LMVoid</span></a></span><span>         </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;void&quot;</span></span><span>
</span><span id="line-80"></span><span>  </span><span class="annot"><a href="GHC.Llvm.Types.html#LMStruct"><span class="hs-identifier hs-type">LMStruct</span></a></span><span> </span><span id="local-6989586621681005748"><span class="annot"><span class="annottext">[LlvmType]
</span><a href="#local-6989586621681005748"><span class="hs-identifier hs-var">tys</span></a></span></span><span>   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;&lt;{&quot;</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmType] -&gt; SDoc
forall a. Outputable a =&gt; [a] -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppCommaJoin"><span class="hs-identifier hs-var">ppCommaJoin</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmType]
</span><a href="#local-6989586621681005748"><span class="hs-identifier hs-var">tys</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;}&gt;&quot;</span></span><span>
</span><span id="line-81"></span><span>  </span><span class="annot"><a href="GHC.Llvm.Types.html#LMStructU"><span class="hs-identifier hs-type">LMStructU</span></a></span><span> </span><span id="local-6989586621681005746"><span class="annot"><span class="annottext">[LlvmType]
</span><a href="#local-6989586621681005746"><span class="hs-identifier hs-var">tys</span></a></span></span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;{&quot;</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmType] -&gt; SDoc
forall a. Outputable a =&gt; [a] -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppCommaJoin"><span class="hs-identifier hs-var">ppCommaJoin</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmType]
</span><a href="#local-6989586621681005746"><span class="hs-identifier hs-var">tys</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;}&quot;</span></span><span>
</span><span id="line-82"></span><span>  </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMMetadata"><span class="hs-identifier hs-var">LMMetadata</span></a></span><span>     </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;metadata&quot;</span></span><span>
</span><span id="line-83"></span><span>  </span><span class="annot"><a href="GHC.Llvm.Types.html#LMAlias"><span class="hs-identifier hs-type">LMAlias</span></a></span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005745"><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005745"><span class="hs-identifier hs-var">s</span></a></span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Char -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#char"><span class="hs-identifier hs-var">char</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'%'</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">FastString -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ftext"><span class="hs-identifier hs-var">ftext</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005745"><span class="hs-identifier hs-var">s</span></a></span><span>
</span><span id="line-84"></span><span>  </span><span class="annot"><a href="GHC.Llvm.Types.html#LMFunction"><span class="hs-identifier hs-type">LMFunction</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmFunctionDecl"><span class="hs-identifier hs-type">LlvmFunctionDecl</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LlvmCallConvention
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005742"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005742"><span class="hs-identifier hs-var">r</span></a></span></span><span> </span><span id="local-6989586621681005741"><span class="annot"><span class="annottext">LlvmParameterListType
</span><a href="#local-6989586621681005741"><span class="hs-identifier hs-var">varg</span></a></span></span><span> </span><span id="local-6989586621681005740"><span class="annot"><span class="annottext">[LlvmParameter]
</span><a href="#local-6989586621681005740"><span class="hs-identifier hs-var">p</span></a></span></span><span> </span><span class="annot"><span class="annottext">LMAlign
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span>
</span><span id="line-85"></span><span>    </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005742"><span class="hs-identifier hs-var">r</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%2B%3E"><span class="hs-operator hs-var">&lt;+&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc
</span><a href="GHC.Utils.Outputable.html#lparen"><span class="hs-identifier hs-var">lparen</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParameterListType -&gt; [LlvmParameter] -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppParams"><span class="hs-identifier hs-var">ppParams</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParameterListType
</span><a href="#local-6989586621681005741"><span class="hs-identifier hs-var">varg</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmParameter]
</span><a href="#local-6989586621681005740"><span class="hs-identifier hs-var">p</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc
</span><a href="GHC.Utils.Outputable.html#rparen"><span class="hs-identifier hs-var">rparen</span></a></span><span>
</span><span id="line-86"></span><span>
</span><span id="line-87"></span><span class="annot"><a href="GHC.Llvm.Types.html#ppParams"><span class="hs-identifier hs-type">ppParams</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmParameterListType"><span class="hs-identifier hs-type">LlvmParameterListType</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmParameter"><span class="hs-identifier hs-type">LlvmParameter</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Utils.Outputable.html#SDoc"><span class="hs-identifier hs-type">SDoc</span></a></span><span>
</span><span id="line-88"></span><span id="ppParams"><span class="annot"><span class="annottext">ppParams :: LlvmParameterListType -&gt; [LlvmParameter] -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppParams"><span class="hs-identifier hs-var hs-var">ppParams</span></a></span></span><span> </span><span id="local-6989586621681005735"><span class="annot"><span class="annottext">LlvmParameterListType
</span><a href="#local-6989586621681005735"><span class="hs-identifier hs-var">varg</span></a></span></span><span> </span><span id="local-6989586621681005734"><span class="annot"><span class="annottext">[LlvmParameter]
</span><a href="#local-6989586621681005734"><span class="hs-identifier hs-var">p</span></a></span></span><span>
</span><span id="line-89"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621681005732"><span class="annot"><span class="annottext">varg' :: PtrString
</span><a href="#local-6989586621681005732"><span class="hs-identifier hs-var hs-var">varg'</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">LlvmParameterListType
</span><a href="#local-6989586621681005735"><span class="hs-identifier hs-var">varg</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-90"></span><span>          </span><span class="annot"><span class="annottext">LlvmParameterListType
</span><a href="GHC.Llvm.Types.html#VarArgs"><span class="hs-identifier hs-var">VarArgs</span></a></span><span> </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">[LlvmType] -&gt; Bool
forall (t :: * -&gt; *) a. Foldable t =&gt; t a -&gt; Bool
</span><a href="../../base/src/Data.Foldable.html#null"><span class="hs-identifier hs-var">null</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmType]
</span><a href="#local-6989586621681005729"><span class="hs-identifier hs-var">args</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; PtrString
</span><a href="GHC.Data.FastString.html#sLit"><span class="hs-identifier hs-var">sLit</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;...&quot;</span></span><span>
</span><span id="line-91"></span><span>                  </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">Bool
</span><a href="../../base/src/GHC.Base.html#otherwise"><span class="hs-identifier hs-var">otherwise</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; PtrString
</span><a href="GHC.Data.FastString.html#sLit"><span class="hs-identifier hs-var">sLit</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;, ...&quot;</span></span><span>
</span><span id="line-92"></span><span>          </span><span id="local-6989586621681005727"><span class="annot"><span class="annottext">LlvmParameterListType
</span><a href="#local-6989586621681005727"><span class="hs-identifier hs-var">_otherwise</span></a></span></span><span>          </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; PtrString
</span><a href="GHC.Data.FastString.html#sLit"><span class="hs-identifier hs-var">sLit</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;&quot;</span></span><span>
</span><span id="line-93"></span><span>        </span><span class="hs-comment">-- by default we don't print param attributes</span><span>
</span><span id="line-94"></span><span>        </span><span id="local-6989586621681005729"><span class="annot"><span class="annottext">args :: [LlvmType]
</span><a href="#local-6989586621681005729"><span class="hs-identifier hs-var hs-var">args</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(LlvmParameter -&gt; LlvmType) -&gt; [LlvmParameter] -&gt; [LlvmType]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParameter -&gt; LlvmType
forall a b. (a, b) -&gt; a
</span><a href="../../base/src/Data.Tuple.html#fst"><span class="hs-identifier hs-var">fst</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmParameter]
</span><a href="#local-6989586621681005734"><span class="hs-identifier hs-var">p</span></a></span><span>
</span><span id="line-95"></span><span>    </span><span class="hs-keyword">in</span><span> </span><span class="annot"><span class="annottext">[LlvmType] -&gt; SDoc
forall a. Outputable a =&gt; [a] -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppCommaJoin"><span class="hs-identifier hs-var">ppCommaJoin</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmType]
</span><a href="#local-6989586621681005729"><span class="hs-identifier hs-var">args</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">PtrString -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ptext"><span class="hs-identifier hs-var">ptext</span></a></span><span> </span><span class="annot"><span class="annottext">PtrString
</span><a href="#local-6989586621681005732"><span class="hs-identifier hs-var">varg'</span></a></span><span>
</span><span id="line-96"></span><span>
</span><span id="line-97"></span><span class="hs-comment">-- | An LLVM section definition. If Nothing then let LLVM decide the section</span><span>
</span><span id="line-98"></span><span class="hs-keyword">type</span><span> </span><span id="LMSection"><span class="annot"><a href="GHC.Llvm.Types.html#LMSection"><span class="hs-identifier hs-var">LMSection</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LMString"><span class="hs-identifier hs-type">LMString</span></a></span><span>
</span><span id="line-99"></span><span class="hs-keyword">type</span><span> </span><span id="LMAlign"><span class="annot"><a href="GHC.Llvm.Types.html#LMAlign"><span class="hs-identifier hs-var">LMAlign</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span>
</span><span id="line-100"></span><span>
</span><span id="line-101"></span><span class="hs-keyword">data</span><span> </span><span id="LMConst"><span class="annot"><a href="GHC.Llvm.Types.html#LMConst"><span class="hs-identifier hs-var">LMConst</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="Global"><span class="annot"><a href="GHC.Llvm.Types.html#Global"><span class="hs-identifier hs-var">Global</span></a></span></span><span>      </span><span class="hs-comment">-- ^ Mutable global variable</span><span>
</span><span id="line-102"></span><span>             </span><span class="hs-glyph">|</span><span> </span><span id="Constant"><span class="annot"><a href="GHC.Llvm.Types.html#Constant"><span class="hs-identifier hs-var">Constant</span></a></span></span><span>    </span><span class="hs-comment">-- ^ Constant global variable</span><span>
</span><span id="line-103"></span><span>             </span><span class="hs-glyph">|</span><span> </span><span id="Alias"><span class="annot"><a href="GHC.Llvm.Types.html#Alias"><span class="hs-identifier hs-var">Alias</span></a></span></span><span>       </span><span class="hs-comment">-- ^ Alias of another variable</span><span>
</span><span id="line-104"></span><span>             </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005719"><span id="local-6989586621681005721"><span class="annot"><span class="annottext">LMConst -&gt; LMConst -&gt; Bool
(LMConst -&gt; LMConst -&gt; Bool)
-&gt; (LMConst -&gt; LMConst -&gt; Bool) -&gt; Eq LMConst
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LMConst -&gt; LMConst -&gt; Bool
$c/= :: LMConst -&gt; LMConst -&gt; Bool
== :: LMConst -&gt; LMConst -&gt; Bool
$c== :: LMConst -&gt; LMConst -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-105"></span><span>
</span><span id="line-106"></span><span class="hs-comment">-- | LLVM Variables</span><span>
</span><span id="line-107"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmVar"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmVar"><span class="hs-identifier hs-var">LlvmVar</span></a></span></span><span>
</span><span id="line-108"></span><span>  </span><span class="hs-comment">-- | Variables with a global scope.</span><span>
</span><span id="line-109"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="LMGlobalVar"><span class="annot"><a href="GHC.Llvm.Types.html#LMGlobalVar"><span class="hs-identifier hs-var">LMGlobalVar</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LMString"><span class="hs-identifier hs-type">LMString</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLinkageType"><span class="hs-identifier hs-type">LlvmLinkageType</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LMSection"><span class="hs-identifier hs-type">LMSection</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LMAlign"><span class="hs-identifier hs-type">LMAlign</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LMConst"><span class="hs-identifier hs-type">LMConst</span></a></span><span>
</span><span id="line-110"></span><span>  </span><span class="hs-comment">-- | Variables local to a function or parameters.</span><span>
</span><span id="line-111"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMLocalVar"><span class="annot"><a href="GHC.Llvm.Types.html#LMLocalVar"><span class="hs-identifier hs-var">LMLocalVar</span></a></span></span><span> </span><span class="annot"><a href="GHC.Types.Unique.html#Unique"><span class="hs-identifier hs-type">Unique</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-112"></span><span>  </span><span class="hs-comment">-- | Named local variables. Sometimes we need to be able to explicitly name</span><span>
</span><span id="line-113"></span><span>  </span><span class="hs-comment">-- variables (e.g for function arguments).</span><span>
</span><span id="line-114"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMNLocalVar"><span class="annot"><a href="GHC.Llvm.Types.html#LMNLocalVar"><span class="hs-identifier hs-var">LMNLocalVar</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LMString"><span class="hs-identifier hs-type">LMString</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-115"></span><span>  </span><span class="hs-comment">-- | A constant variable</span><span>
</span><span id="line-116"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMLitVar"><span class="annot"><a href="GHC.Llvm.Types.html#LMLitVar"><span class="hs-identifier hs-var">LMLitVar</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLit"><span class="hs-identifier hs-type">LlvmLit</span></a></span><span>
</span><span id="line-117"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005697"><span id="local-6989586621681005713"><span class="annot"><span class="annottext">LlvmVar -&gt; LlvmVar -&gt; Bool
(LlvmVar -&gt; LlvmVar -&gt; Bool)
-&gt; (LlvmVar -&gt; LlvmVar -&gt; Bool) -&gt; Eq LlvmVar
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmVar -&gt; LlvmVar -&gt; Bool
$c/= :: LlvmVar -&gt; LlvmVar -&gt; Bool
== :: LlvmVar -&gt; LlvmVar -&gt; Bool
$c== :: LlvmVar -&gt; LlvmVar -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-118"></span><span>
</span><span id="line-119"></span><span class="hs-comment">-- | Llvm Literal Data.</span><span>
</span><span id="line-120"></span><span class="hs-comment">--</span><span>
</span><span id="line-121"></span><span class="hs-comment">-- These can be used inline in expressions.</span><span>
</span><span id="line-122"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmLit"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLit"><span class="hs-identifier hs-var">LlvmLit</span></a></span></span><span>
</span><span id="line-123"></span><span>  </span><span class="hs-comment">-- | Refers to an integer constant (i64 42).</span><span>
</span><span id="line-124"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="LMIntLit"><span class="annot"><a href="GHC.Llvm.Types.html#LMIntLit"><span class="hs-identifier hs-var">LMIntLit</span></a></span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Integer</span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-125"></span><span>  </span><span class="hs-comment">-- | Floating point literal</span><span>
</span><span id="line-126"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMFloatLit"><span class="annot"><a href="GHC.Llvm.Types.html#LMFloatLit"><span class="hs-identifier hs-var">LMFloatLit</span></a></span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Double</span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-127"></span><span>  </span><span class="hs-comment">-- | Literal NULL, only applicable to pointer types</span><span>
</span><span id="line-128"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMNullLit"><span class="annot"><a href="GHC.Llvm.Types.html#LMNullLit"><span class="hs-identifier hs-var">LMNullLit</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-129"></span><span>  </span><span class="hs-comment">-- | Vector literal</span><span>
</span><span id="line-130"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMVectorLit"><span class="annot"><a href="GHC.Llvm.Types.html#LMVectorLit"><span class="hs-identifier hs-var">LMVectorLit</span></a></span></span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLit"><span class="hs-identifier hs-type">LlvmLit</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-131"></span><span>  </span><span class="hs-comment">-- | Undefined value, random bit pattern. Useful for optimisations.</span><span>
</span><span id="line-132"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMUndefLit"><span class="annot"><a href="GHC.Llvm.Types.html#LMUndefLit"><span class="hs-identifier hs-var">LMUndefLit</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-133"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005678"><span id="local-6989586621681005690"><span class="annot"><span class="annottext">LlvmLit -&gt; LlvmLit -&gt; Bool
(LlvmLit -&gt; LlvmLit -&gt; Bool)
-&gt; (LlvmLit -&gt; LlvmLit -&gt; Bool) -&gt; Eq LlvmLit
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmLit -&gt; LlvmLit -&gt; Bool
$c/= :: LlvmLit -&gt; LlvmLit -&gt; Bool
== :: LlvmLit -&gt; LlvmLit -&gt; Bool
$c== :: LlvmLit -&gt; LlvmLit -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-134"></span><span>
</span><span id="line-135"></span><span class="hs-comment">-- | Llvm Static Data.</span><span>
</span><span id="line-136"></span><span class="hs-comment">--</span><span>
</span><span id="line-137"></span><span class="hs-comment">-- These represent the possible global level variables and constants.</span><span>
</span><span id="line-138"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmStatic"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-var">LlvmStatic</span></a></span></span><span>
</span><span id="line-139"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="LMComment"><span class="annot"><a href="GHC.Llvm.Types.html#LMComment"><span class="hs-identifier hs-var">LMComment</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LMString"><span class="hs-identifier hs-type">LMString</span></a></span><span>                  </span><span class="hs-comment">-- ^ A comment in a static section</span><span>
</span><span id="line-140"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMStaticLit"><span class="annot"><a href="GHC.Llvm.Types.html#LMStaticLit"><span class="hs-identifier hs-var">LMStaticLit</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLit"><span class="hs-identifier hs-type">LlvmLit</span></a></span><span>                 </span><span class="hs-comment">-- ^ A static variant of a literal value</span><span>
</span><span id="line-141"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMUninitType"><span class="annot"><a href="GHC.Llvm.Types.html#LMUninitType"><span class="hs-identifier hs-var">LMUninitType</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>               </span><span class="hs-comment">-- ^ For uninitialised data</span><span>
</span><span id="line-142"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMStaticStr"><span class="annot"><a href="GHC.Llvm.Types.html#LMStaticStr"><span class="hs-identifier hs-var">LMStaticStr</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LMString"><span class="hs-identifier hs-type">LMString</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>       </span><span class="hs-comment">-- ^ Defines a static 'LMString'</span><span>
</span><span id="line-143"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMStaticArray"><span class="annot"><a href="GHC.Llvm.Types.html#LMStaticArray"><span class="hs-identifier hs-var">LMStaticArray</span></a></span></span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span class="hs-special">]</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-comment">-- ^ A static array</span><span>
</span><span id="line-144"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMStaticStruc"><span class="annot"><a href="GHC.Llvm.Types.html#LMStaticStruc"><span class="hs-identifier hs-var">LMStaticStruc</span></a></span></span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span class="hs-special">]</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-comment">-- ^ A static structure type</span><span>
</span><span id="line-145"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMStaticPointer"><span class="annot"><a href="GHC.Llvm.Types.html#LMStaticPointer"><span class="hs-identifier hs-var">LMStaticPointer</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmVar"><span class="hs-identifier hs-type">LlvmVar</span></a></span><span>             </span><span class="hs-comment">-- ^ A pointer to other data</span><span>
</span><span id="line-146"></span><span>
</span><span id="line-147"></span><span>  </span><span class="hs-comment">-- static expressions, could split out but leave</span><span>
</span><span id="line-148"></span><span>  </span><span class="hs-comment">-- for moment for ease of use. Not many of them.</span><span>
</span><span id="line-149"></span><span>
</span><span id="line-150"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMTrunc"><span class="annot"><a href="GHC.Llvm.Types.html#LMTrunc"><span class="hs-identifier hs-var">LMTrunc</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>        </span><span class="hs-comment">-- ^ Truncate</span><span>
</span><span id="line-151"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMBitc"><span class="annot"><a href="GHC.Llvm.Types.html#LMBitc"><span class="hs-identifier hs-var">LMBitc</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>         </span><span class="hs-comment">-- ^ Pointer to Pointer conversion</span><span>
</span><span id="line-152"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMPtoI"><span class="annot"><a href="GHC.Llvm.Types.html#LMPtoI"><span class="hs-identifier hs-var">LMPtoI</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>         </span><span class="hs-comment">-- ^ Pointer to Integer conversion</span><span>
</span><span id="line-153"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMAdd"><span class="annot"><a href="GHC.Llvm.Types.html#LMAdd"><span class="hs-identifier hs-var">LMAdd</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span>        </span><span class="hs-comment">-- ^ Constant addition operation</span><span>
</span><span id="line-154"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LMSub"><span class="annot"><a href="GHC.Llvm.Types.html#LMSub"><span class="hs-identifier hs-var">LMSub</span></a></span></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span>        </span><span class="hs-comment">-- ^ Constant subtraction operation</span><span>
</span><span id="line-155"></span><span>
</span><span id="line-156"></span><span class="hs-comment">-- -----------------------------------------------------------------------------</span><span>
</span><span id="line-157"></span><span class="hs-comment">-- ** Operations on LLVM Basic Types and Variables</span><span>
</span><span id="line-158"></span><span class="hs-comment">--</span><span>
</span><span id="line-159"></span><span>
</span><span id="line-160"></span><span class="hs-comment">-- | LLVM code generator options</span><span>
</span><span id="line-161"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmOpts"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmOpts"><span class="hs-identifier hs-var">LlvmOpts</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="LlvmOpts"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmOpts"><span class="hs-identifier hs-var">LlvmOpts</span></a></span></span><span>
</span><span id="line-162"></span><span>   </span><span class="hs-special">{</span><span> </span><span id="llvmOptsPlatform"><span class="annot"><span class="annottext">LlvmOpts -&gt; Platform
</span><a href="GHC.Llvm.Types.html#llvmOptsPlatform"><span class="hs-identifier hs-var hs-var">llvmOptsPlatform</span></a></span></span><span>             </span><span class="hs-glyph">::</span><span> </span><span class="hs-glyph">!</span><span class="annot"><a href="../../ghc-boot/src/GHC.Platform.html#Platform"><span class="hs-identifier hs-type">Platform</span></a></span><span> </span><span class="hs-comment">-- ^ Target platform</span><span>
</span><span id="line-163"></span><span>   </span><span class="hs-special">,</span><span> </span><span id="llvmOptsFillUndefWithGarbage"><span class="annot"><span class="annottext">LlvmOpts -&gt; Bool
</span><a href="GHC.Llvm.Types.html#llvmOptsFillUndefWithGarbage"><span class="hs-identifier hs-var hs-var">llvmOptsFillUndefWithGarbage</span></a></span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-glyph">!</span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>     </span><span class="hs-comment">-- ^ Fill undefined literals with garbage values</span><span>
</span><span id="line-164"></span><span>   </span><span class="hs-special">,</span><span> </span><span id="llvmOptsSplitSections"><span class="annot"><span class="annottext">LlvmOpts -&gt; Bool
</span><a href="GHC.Llvm.Types.html#llvmOptsSplitSections"><span class="hs-identifier hs-var hs-var">llvmOptsSplitSections</span></a></span></span><span>        </span><span class="hs-glyph">::</span><span> </span><span class="hs-glyph">!</span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>     </span><span class="hs-comment">-- ^ Split sections</span><span>
</span><span id="line-165"></span><span>   </span><span class="hs-special">}</span><span>
</span><span id="line-166"></span><span>
</span><span id="line-167"></span><span class="hs-comment">-- | Get LlvmOptions from DynFlags</span><span>
</span><span id="line-168"></span><span class="annot"><a href="GHC.Llvm.Types.html#initLlvmOpts"><span class="hs-identifier hs-type">initLlvmOpts</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Driver.Session.html#DynFlags"><span class="hs-identifier hs-type">DynFlags</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmOpts"><span class="hs-identifier hs-type">LlvmOpts</span></a></span><span>
</span><span id="line-169"></span><span id="initLlvmOpts"><span class="annot"><span class="annottext">initLlvmOpts :: DynFlags -&gt; LlvmOpts
</span><a href="GHC.Llvm.Types.html#initLlvmOpts"><span class="hs-identifier hs-var hs-var">initLlvmOpts</span></a></span></span><span> </span><span id="local-6989586621681005660"><span class="annot"><span class="annottext">DynFlags
</span><a href="#local-6989586621681005660"><span class="hs-identifier hs-var">dflags</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmOpts :: Platform -&gt; Bool -&gt; Bool -&gt; LlvmOpts
</span><a href="GHC.Llvm.Types.html#LlvmOpts"><span class="hs-identifier hs-type">LlvmOpts</span></a></span><span>
</span><span id="line-170"></span><span>   </span><span class="hs-special">{</span><span> </span><span class="annot"><span class="annottext">llvmOptsPlatform :: Platform
</span><a href="GHC.Llvm.Types.html#llvmOptsPlatform"><span class="hs-identifier hs-var">llvmOptsPlatform</span></a></span><span>             </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">DynFlags -&gt; Platform
</span><a href="GHC.Driver.Session.html#targetPlatform"><span class="hs-identifier hs-var hs-var">targetPlatform</span></a></span><span> </span><span class="annot"><span class="annottext">DynFlags
</span><a href="#local-6989586621681005660"><span class="hs-identifier hs-var">dflags</span></a></span><span>
</span><span id="line-171"></span><span>   </span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">llvmOptsFillUndefWithGarbage :: Bool
</span><a href="GHC.Llvm.Types.html#llvmOptsFillUndefWithGarbage"><span class="hs-identifier hs-var">llvmOptsFillUndefWithGarbage</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">GeneralFlag -&gt; DynFlags -&gt; Bool
</span><a href="GHC.Driver.Session.html#gopt"><span class="hs-identifier hs-var">gopt</span></a></span><span> </span><span class="annot"><span class="annottext">GeneralFlag
</span><a href="GHC.Driver.Flags.html#Opt_LlvmFillUndefWithGarbage"><span class="hs-identifier hs-var">Opt_LlvmFillUndefWithGarbage</span></a></span><span> </span><span class="annot"><span class="annottext">DynFlags
</span><a href="#local-6989586621681005660"><span class="hs-identifier hs-var">dflags</span></a></span><span>
</span><span id="line-172"></span><span>   </span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">llvmOptsSplitSections :: Bool
</span><a href="GHC.Llvm.Types.html#llvmOptsSplitSections"><span class="hs-identifier hs-var">llvmOptsSplitSections</span></a></span><span>        </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">GeneralFlag -&gt; DynFlags -&gt; Bool
</span><a href="GHC.Driver.Session.html#gopt"><span class="hs-identifier hs-var">gopt</span></a></span><span> </span><span class="annot"><span class="annottext">GeneralFlag
</span><a href="GHC.Driver.Flags.html#Opt_SplitSections"><span class="hs-identifier hs-var">Opt_SplitSections</span></a></span><span> </span><span class="annot"><span class="annottext">DynFlags
</span><a href="#local-6989586621681005660"><span class="hs-identifier hs-var">dflags</span></a></span><span>
</span><span id="line-173"></span><span>   </span><span class="hs-special">}</span><span>
</span><span id="line-174"></span><span>
</span><span id="line-175"></span><span class="annot"><a href="GHC.Llvm.Types.html#garbageLit"><span class="hs-identifier hs-type">garbageLit</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLit"><span class="hs-identifier hs-type">LlvmLit</span></a></span><span>
</span><span id="line-176"></span><span id="garbageLit"><span class="annot"><span class="annottext">garbageLit :: LlvmType -&gt; Maybe LlvmLit
</span><a href="GHC.Llvm.Types.html#garbageLit"><span class="hs-identifier hs-var hs-var">garbageLit</span></a></span></span><span> </span><span id="local-6989586621681005654"><span class="annot"><span class="annottext">t :: LlvmType
</span><a href="#local-6989586621681005654"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-glyph">@</span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-type">LMInt</span></a></span><span> </span><span id="local-6989586621681005653"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005653"><span class="hs-identifier hs-var">w</span></a></span></span><span class="hs-special">)</span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmLit -&gt; Maybe LlvmLit
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Integer -&gt; LlvmType -&gt; LlvmLit
</span><a href="GHC.Llvm.Types.html#LMIntLit"><span class="hs-identifier hs-var">LMIntLit</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Integer
</span><span class="hs-number">0xbbbbbbbbbbbbbbb0</span></span><span> </span><span class="annot"><span class="annottext">Integer -&gt; Integer -&gt; Integer
forall a. Integral a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Real.html#mod"><span class="hs-operator hs-var">`mod`</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Integer
</span><span class="hs-number">2</span></span><span class="annot"><span class="annottext">Integer -&gt; Int -&gt; Integer
forall a b. (Num a, Integral b) =&gt; a -&gt; b -&gt; a
</span><a href="../../base/src/GHC.Real.html#%5E"><span class="hs-operator hs-var">^</span></a></span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005653"><span class="hs-identifier hs-var">w</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005654"><span class="hs-identifier hs-var">t</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-177"></span><span>  </span><span class="hs-comment">-- Use a value that looks like an untagged pointer, so we are more</span><span>
</span><span id="line-178"></span><span>  </span><span class="hs-comment">-- likely to try to enter it</span><span>
</span><span id="line-179"></span><span class="annot"><a href="GHC.Llvm.Types.html#garbageLit"><span class="hs-identifier hs-var">garbageLit</span></a></span><span> </span><span id="local-6989586621681005650"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005650"><span class="hs-identifier hs-var">t</span></a></span></span><span>
</span><span id="line-180"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; Bool
</span><a href="GHC.Llvm.Types.html#isFloat"><span class="hs-identifier hs-var">isFloat</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005650"><span class="hs-identifier hs-var">t</span></a></span><span>              </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmLit -&gt; Maybe LlvmLit
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Double -&gt; LlvmType -&gt; LlvmLit
</span><a href="GHC.Llvm.Types.html#LMFloatLit"><span class="hs-identifier hs-var">LMFloatLit</span></a></span><span> </span><span class="annot"><span class="annottext">Double
</span><span class="hs-number">12345678.9</span></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005650"><span class="hs-identifier hs-var">t</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-181"></span><span class="annot"><a href="GHC.Llvm.Types.html#garbageLit"><span class="hs-identifier hs-var">garbageLit</span></a></span><span> </span><span id="local-6989586621681005648"><span class="annot"><span class="annottext">t :: LlvmType
</span><a href="#local-6989586621681005648"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-glyph">@</span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMPointer"><span class="hs-identifier hs-type">LMPointer</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmLit -&gt; Maybe LlvmLit
forall a. a -&gt; Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-var">Just</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType -&gt; LlvmLit
</span><a href="GHC.Llvm.Types.html#LMNullLit"><span class="hs-identifier hs-var">LMNullLit</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005648"><span class="hs-identifier hs-var">t</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-182"></span><span>  </span><span class="hs-comment">-- Using null isn't totally ideal, since some functions may check for null.</span><span>
</span><span id="line-183"></span><span>  </span><span class="hs-comment">-- But producing another value is inconvenient since it needs a cast,</span><span>
</span><span id="line-184"></span><span>  </span><span class="hs-comment">-- and the knowledge for how to format casts is in PpLlvm.</span><span>
</span><span id="line-185"></span><span class="annot"><a href="GHC.Llvm.Types.html#garbageLit"><span class="hs-identifier hs-var">garbageLit</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span>               </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Maybe LlvmLit
forall a. Maybe a
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span>
</span><span id="line-186"></span><span>  </span><span class="hs-comment">-- More cases could be added, but this should do for now.</span><span>
</span><span id="line-187"></span><span>
</span><span id="line-188"></span><span class="hs-comment">-- | Return the 'LlvmType' of the 'LlvmVar'</span><span>
</span><span id="line-189"></span><span class="annot"><a href="GHC.Llvm.Types.html#getVarType"><span class="hs-identifier hs-type">getVarType</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmVar"><span class="hs-identifier hs-type">LlvmVar</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-190"></span><span id="getVarType"><span class="annot"><span class="annottext">getVarType :: LlvmVar -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#getVarType"><span class="hs-identifier hs-var hs-var">getVarType</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMGlobalVar"><span class="hs-identifier hs-type">LMGlobalVar</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005646"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005646"><span class="hs-identifier hs-var">y</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LMSection
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LMAlign
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LMConst
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005646"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-191"></span><span class="annot"><a href="GHC.Llvm.Types.html#getVarType"><span class="hs-identifier hs-var">getVarType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMLocalVar"><span class="hs-identifier hs-type">LMLocalVar</span></a></span><span>  </span><span class="annot"><span class="annottext">Unique
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005645"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005645"><span class="hs-identifier hs-var">y</span></a></span></span><span>        </span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005645"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-192"></span><span class="annot"><a href="GHC.Llvm.Types.html#getVarType"><span class="hs-identifier hs-var">getVarType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMNLocalVar"><span class="hs-identifier hs-type">LMNLocalVar</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005644"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005644"><span class="hs-identifier hs-var">y</span></a></span></span><span>        </span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005644"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-193"></span><span class="annot"><a href="GHC.Llvm.Types.html#getVarType"><span class="hs-identifier hs-var">getVarType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMLitVar"><span class="hs-identifier hs-type">LMLitVar</span></a></span><span>    </span><span id="local-6989586621681005643"><span class="annot"><span class="annottext">LlvmLit
</span><a href="#local-6989586621681005643"><span class="hs-identifier hs-var">l</span></a></span></span><span>          </span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmLit -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#getLitType"><span class="hs-identifier hs-var">getLitType</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmLit
</span><a href="#local-6989586621681005643"><span class="hs-identifier hs-var">l</span></a></span><span>
</span><span id="line-194"></span><span>
</span><span id="line-195"></span><span class="hs-comment">-- | Return the 'LlvmType' of a 'LlvmLit'</span><span>
</span><span id="line-196"></span><span class="annot"><a href="GHC.Llvm.Types.html#getLitType"><span class="hs-identifier hs-type">getLitType</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLit"><span class="hs-identifier hs-type">LlvmLit</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-197"></span><span id="getLitType"><span class="annot"><span class="annottext">getLitType :: LlvmLit -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#getLitType"><span class="hs-identifier hs-var hs-var">getLitType</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMIntLit"><span class="hs-identifier hs-type">LMIntLit</span></a></span><span>   </span><span class="annot"><span class="annottext">Integer
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005641"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005641"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005641"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-198"></span><span class="annot"><a href="GHC.Llvm.Types.html#getLitType"><span class="hs-identifier hs-var">getLitType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMFloatLit"><span class="hs-identifier hs-type">LMFloatLit</span></a></span><span> </span><span class="annot"><span class="annottext">Double
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005640"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005640"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005640"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-199"></span><span class="annot"><a href="GHC.Llvm.Types.html#getLitType"><span class="hs-identifier hs-var">getLitType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMVectorLit"><span class="hs-identifier hs-type">LMVectorLit</span></a></span><span> </span><span class="hs-special">[</span><span class="hs-special">]</span><span class="hs-special">)</span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; LlvmType
forall a. String -&gt; a
</span><a href="GHC.Utils.Panic.Plain.html#panic"><span class="hs-identifier hs-var">panic</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;getLitType&quot;</span></span><span>
</span><span id="line-200"></span><span class="annot"><a href="GHC.Llvm.Types.html#getLitType"><span class="hs-identifier hs-var">getLitType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMVectorLit"><span class="hs-identifier hs-type">LMVectorLit</span></a></span><span> </span><span id="local-6989586621681005638"><span class="annot"><span class="annottext">[LlvmLit]
</span><a href="#local-6989586621681005638"><span class="hs-identifier hs-var">ls</span></a></span></span><span class="hs-special">)</span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#LMVector"><span class="hs-identifier hs-var">LMVector</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">[LlvmLit] -&gt; Int
forall (t :: * -&gt; *) a. Foldable t =&gt; t a -&gt; Int
</span><a href="../../base/src/Data.Foldable.html#length"><span class="hs-identifier hs-var">length</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmLit]
</span><a href="#local-6989586621681005638"><span class="hs-identifier hs-var">ls</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmLit -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#getLitType"><span class="hs-identifier hs-var">getLitType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">[LlvmLit] -&gt; LlvmLit
forall a. [a] -&gt; a
</span><a href="../../base/src/GHC.List.html#head"><span class="hs-identifier hs-var">head</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmLit]
</span><a href="#local-6989586621681005638"><span class="hs-identifier hs-var">ls</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-201"></span><span class="annot"><a href="GHC.Llvm.Types.html#getLitType"><span class="hs-identifier hs-var">getLitType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMNullLit"><span class="hs-identifier hs-type">LMNullLit</span></a></span><span>    </span><span id="local-6989586621681005635"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005635"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005635"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-202"></span><span class="annot"><a href="GHC.Llvm.Types.html#getLitType"><span class="hs-identifier hs-var">getLitType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMUndefLit"><span class="hs-identifier hs-type">LMUndefLit</span></a></span><span>   </span><span id="local-6989586621681005634"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005634"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005634"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-203"></span><span>
</span><span id="line-204"></span><span class="hs-comment">-- | Return the 'LlvmType' of the 'LlvmStatic'</span><span>
</span><span id="line-205"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-type">getStatType</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmStatic"><span class="hs-identifier hs-type">LlvmStatic</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-206"></span><span id="getStatType"><span class="annot"><span class="annottext">getStatType :: LlvmStatic -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var hs-var">getStatType</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMStaticLit"><span class="hs-identifier hs-type">LMStaticLit</span></a></span><span>   </span><span id="local-6989586621681005632"><span class="annot"><span class="annottext">LlvmLit
</span><a href="#local-6989586621681005632"><span class="hs-identifier hs-var">l</span></a></span></span><span>  </span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmLit -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#getLitType"><span class="hs-identifier hs-var">getLitType</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmLit
</span><a href="#local-6989586621681005632"><span class="hs-identifier hs-var">l</span></a></span><span>
</span><span id="line-207"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMUninitType"><span class="hs-identifier hs-type">LMUninitType</span></a></span><span>    </span><span id="local-6989586621681005631"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005631"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005631"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-208"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMStaticStr"><span class="hs-identifier hs-type">LMStaticStr</span></a></span><span>   </span><span class="annot"><span class="annottext">FastString
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005630"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005630"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005630"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-209"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMStaticArray"><span class="hs-identifier hs-type">LMStaticArray</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmStatic]
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005629"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005629"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005629"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-210"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMStaticStruc"><span class="hs-identifier hs-type">LMStaticStruc</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmStatic]
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005628"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005628"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005628"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-211"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMStaticPointer"><span class="hs-identifier hs-type">LMStaticPointer</span></a></span><span> </span><span id="local-6989586621681005627"><span class="annot"><span class="annottext">LlvmVar
</span><a href="#local-6989586621681005627"><span class="hs-identifier hs-var">v</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmVar -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#getVarType"><span class="hs-identifier hs-var">getVarType</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmVar
</span><a href="#local-6989586621681005627"><span class="hs-identifier hs-var">v</span></a></span><span>
</span><span id="line-212"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMTrunc"><span class="hs-identifier hs-type">LMTrunc</span></a></span><span>       </span><span class="annot"><span class="annottext">LlvmStatic
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005626"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005626"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005626"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-213"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMBitc"><span class="hs-identifier hs-type">LMBitc</span></a></span><span>        </span><span class="annot"><span class="annottext">LlvmStatic
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005625"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005625"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005625"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-214"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMPtoI"><span class="hs-identifier hs-type">LMPtoI</span></a></span><span>        </span><span class="annot"><span class="annottext">LlvmStatic
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005624"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005624"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005624"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-215"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMAdd"><span class="hs-identifier hs-type">LMAdd</span></a></span><span>         </span><span id="local-6989586621681005623"><span class="annot"><span class="annottext">LlvmStatic
</span><a href="#local-6989586621681005623"><span class="hs-identifier hs-var">t</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmStatic
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmStatic -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmStatic
</span><a href="#local-6989586621681005623"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-216"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMSub"><span class="hs-identifier hs-type">LMSub</span></a></span><span>         </span><span id="local-6989586621681005622"><span class="annot"><span class="annottext">LlvmStatic
</span><a href="#local-6989586621681005622"><span class="hs-identifier hs-var">t</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmStatic
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmStatic -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmStatic
</span><a href="#local-6989586621681005622"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-217"></span><span class="annot"><a href="GHC.Llvm.Types.html#getStatType"><span class="hs-identifier hs-var">getStatType</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMComment"><span class="hs-identifier hs-type">LMComment</span></a></span><span>       </span><span class="annot"><span class="annottext">FastString
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; LlvmType
forall a. HasCallStack =&gt; String -&gt; a
</span><a href="../../base/src/GHC.Err.html#error"><span class="hs-identifier hs-var">error</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Can't call getStatType on LMComment!&quot;</span></span><span>
</span><span id="line-218"></span><span>
</span><span id="line-219"></span><span class="hs-comment">-- | Return the 'LlvmLinkageType' for a 'LlvmVar'</span><span>
</span><span id="line-220"></span><span class="annot"><a href="GHC.Llvm.Types.html#getLink"><span class="hs-identifier hs-type">getLink</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmVar"><span class="hs-identifier hs-type">LlvmVar</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLinkageType"><span class="hs-identifier hs-type">LlvmLinkageType</span></a></span><span>
</span><span id="line-221"></span><span id="getLink"><span class="annot"><span class="annottext">getLink :: LlvmVar -&gt; LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#getLink"><span class="hs-identifier hs-var hs-var">getLink</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMGlobalVar"><span class="hs-identifier hs-type">LMGlobalVar</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span> </span><span id="local-6989586621681005619"><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="#local-6989586621681005619"><span class="hs-identifier hs-var">l</span></a></span></span><span> </span><span class="annot"><span class="annottext">LMSection
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LMAlign
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LMConst
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="#local-6989586621681005619"><span class="hs-identifier hs-var">l</span></a></span><span>
</span><span id="line-222"></span><span class="annot"><a href="GHC.Llvm.Types.html#getLink"><span class="hs-identifier hs-var">getLink</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmVar
</span><span class="hs-identifier">_</span></span><span>                         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#Internal"><span class="hs-identifier hs-var">Internal</span></a></span><span>
</span><span id="line-223"></span><span>
</span><span id="line-224"></span><span class="hs-comment">-- | Add a pointer indirection to the supplied type. 'LMLabel' and 'LMVoid'</span><span>
</span><span id="line-225"></span><span class="hs-comment">-- cannot be lifted.</span><span>
</span><span id="line-226"></span><span class="annot"><a href="GHC.Llvm.Types.html#pLift"><span class="hs-identifier hs-type">pLift</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-227"></span><span id="pLift"><span class="annot"><span class="annottext">pLift :: LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#pLift"><span class="hs-identifier hs-var hs-var">pLift</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMLabel"><span class="hs-identifier hs-var">LMLabel</span></a></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; LlvmType
forall a. HasCallStack =&gt; String -&gt; a
</span><a href="../../base/src/GHC.Err.html#error"><span class="hs-identifier hs-var">error</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Labels are unliftable&quot;</span></span><span>
</span><span id="line-228"></span><span class="annot"><a href="GHC.Llvm.Types.html#pLift"><span class="hs-identifier hs-var">pLift</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMVoid"><span class="hs-identifier hs-var">LMVoid</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; LlvmType
forall a. HasCallStack =&gt; String -&gt; a
</span><a href="../../base/src/GHC.Err.html#error"><span class="hs-identifier hs-var">error</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Voids are unliftable&quot;</span></span><span>
</span><span id="line-229"></span><span class="annot"><a href="GHC.Llvm.Types.html#pLift"><span class="hs-identifier hs-var">pLift</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMMetadata"><span class="hs-identifier hs-var">LMMetadata</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; LlvmType
forall a. HasCallStack =&gt; String -&gt; a
</span><a href="../../base/src/GHC.Err.html#error"><span class="hs-identifier hs-var">error</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Metadatas are unliftable&quot;</span></span><span>
</span><span id="line-230"></span><span class="annot"><a href="GHC.Llvm.Types.html#pLift"><span class="hs-identifier hs-var">pLift</span></a></span><span> </span><span id="local-6989586621681005616"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005616"><span class="hs-identifier hs-var">x</span></a></span></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#LMPointer"><span class="hs-identifier hs-var">LMPointer</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005616"><span class="hs-identifier hs-var">x</span></a></span><span>
</span><span id="line-231"></span><span>
</span><span id="line-232"></span><span class="hs-comment">-- | Lift a variable to 'LMPointer' type.</span><span>
</span><span id="line-233"></span><span class="annot"><a href="GHC.Llvm.Types.html#pVarLift"><span class="hs-identifier hs-type">pVarLift</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmVar"><span class="hs-identifier hs-type">LlvmVar</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmVar"><span class="hs-identifier hs-type">LlvmVar</span></a></span><span>
</span><span id="line-234"></span><span id="pVarLift"><span class="annot"><span class="annottext">pVarLift :: LlvmVar -&gt; LlvmVar
</span><a href="GHC.Llvm.Types.html#pVarLift"><span class="hs-identifier hs-var hs-var">pVarLift</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMGlobalVar"><span class="hs-identifier hs-type">LMGlobalVar</span></a></span><span> </span><span id="local-6989586621681005614"><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005614"><span class="hs-identifier hs-var">s</span></a></span></span><span> </span><span id="local-6989586621681005613"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005613"><span class="hs-identifier hs-var">t</span></a></span></span><span> </span><span id="local-6989586621681005612"><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="#local-6989586621681005612"><span class="hs-identifier hs-var">l</span></a></span></span><span> </span><span id="local-6989586621681005611"><span class="annot"><span class="annottext">LMSection
</span><a href="#local-6989586621681005611"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621681005610"><span class="annot"><span class="annottext">LMAlign
</span><a href="#local-6989586621681005610"><span class="hs-identifier hs-var">a</span></a></span></span><span> </span><span id="local-6989586621681005609"><span class="annot"><span class="annottext">LMConst
</span><a href="#local-6989586621681005609"><span class="hs-identifier hs-var">c</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">FastString
-&gt; LlvmType
-&gt; LlvmLinkageType
-&gt; LMSection
-&gt; LMAlign
-&gt; LMConst
-&gt; LlvmVar
</span><a href="GHC.Llvm.Types.html#LMGlobalVar"><span class="hs-identifier hs-var">LMGlobalVar</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005614"><span class="hs-identifier hs-var">s</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#pLift"><span class="hs-identifier hs-var">pLift</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005613"><span class="hs-identifier hs-var">t</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="#local-6989586621681005612"><span class="hs-identifier hs-var">l</span></a></span><span> </span><span class="annot"><span class="annottext">LMSection
</span><a href="#local-6989586621681005611"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">LMAlign
</span><a href="#local-6989586621681005610"><span class="hs-identifier hs-var">a</span></a></span><span> </span><span class="annot"><span class="annottext">LMConst
</span><a href="#local-6989586621681005609"><span class="hs-identifier hs-var">c</span></a></span><span>
</span><span id="line-235"></span><span class="annot"><a href="GHC.Llvm.Types.html#pVarLift"><span class="hs-identifier hs-var">pVarLift</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMLocalVar"><span class="hs-identifier hs-type">LMLocalVar</span></a></span><span>  </span><span id="local-6989586621681005608"><span class="annot"><span class="annottext">Unique
</span><a href="#local-6989586621681005608"><span class="hs-identifier hs-var">s</span></a></span></span><span> </span><span id="local-6989586621681005607"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005607"><span class="hs-identifier hs-var">t</span></a></span></span><span>        </span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Unique -&gt; LlvmType -&gt; LlvmVar
</span><a href="GHC.Llvm.Types.html#LMLocalVar"><span class="hs-identifier hs-var">LMLocalVar</span></a></span><span>  </span><span class="annot"><span class="annottext">Unique
</span><a href="#local-6989586621681005608"><span class="hs-identifier hs-var">s</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#pLift"><span class="hs-identifier hs-var">pLift</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005607"><span class="hs-identifier hs-var">t</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-236"></span><span class="annot"><a href="GHC.Llvm.Types.html#pVarLift"><span class="hs-identifier hs-var">pVarLift</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMNLocalVar"><span class="hs-identifier hs-type">LMNLocalVar</span></a></span><span> </span><span id="local-6989586621681005606"><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005606"><span class="hs-identifier hs-var">s</span></a></span></span><span> </span><span id="local-6989586621681005605"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005605"><span class="hs-identifier hs-var">t</span></a></span></span><span>        </span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">FastString -&gt; LlvmType -&gt; LlvmVar
</span><a href="GHC.Llvm.Types.html#LMNLocalVar"><span class="hs-identifier hs-var">LMNLocalVar</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005606"><span class="hs-identifier hs-var">s</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#pLift"><span class="hs-identifier hs-var">pLift</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005605"><span class="hs-identifier hs-var">t</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-237"></span><span class="annot"><a href="GHC.Llvm.Types.html#pVarLift"><span class="hs-identifier hs-var">pVarLift</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMLitVar"><span class="hs-identifier hs-type">LMLitVar</span></a></span><span>    </span><span class="annot"><span class="annottext">LlvmLit
</span><span class="hs-identifier">_</span></span><span>          </span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; LlvmVar
forall a. HasCallStack =&gt; String -&gt; a
</span><a href="../../base/src/GHC.Err.html#error"><span class="hs-identifier hs-var">error</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; LlvmVar) -&gt; String -&gt; LlvmVar
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Can't lower a literal type!&quot;</span></span><span>
</span><span id="line-238"></span><span>
</span><span id="line-239"></span><span class="hs-comment">-- | Remove the pointer indirection of the supplied type. Only 'LMPointer'</span><span>
</span><span id="line-240"></span><span class="hs-comment">-- constructors can be lowered.</span><span>
</span><span id="line-241"></span><span class="annot"><a href="GHC.Llvm.Types.html#pLower"><span class="hs-identifier hs-type">pLower</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-242"></span><span id="pLower"><span class="annot"><span class="annottext">pLower :: LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#pLower"><span class="hs-identifier hs-var hs-var">pLower</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMPointer"><span class="hs-identifier hs-type">LMPointer</span></a></span><span> </span><span id="local-6989586621681005603"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005603"><span class="hs-identifier hs-var">x</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005603"><span class="hs-identifier hs-var">x</span></a></span><span>
</span><span id="line-243"></span><span class="annot"><a href="GHC.Llvm.Types.html#pLower"><span class="hs-identifier hs-var">pLower</span></a></span><span> </span><span id="local-6989586621681005602"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005602"><span class="hs-identifier hs-var">x</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc -&gt; LlvmType
forall a. HasCallStack =&gt; String -&gt; SDoc -&gt; a
</span><a href="GHC.Utils.Outputable.html#pprPanic"><span class="hs-identifier hs-var">pprPanic</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;llvmGen(pLower)&quot;</span></span><span>
</span><span id="line-244"></span><span>            </span><span class="annot"><span class="annottext">(SDoc -&gt; LlvmType) -&gt; SDoc -&gt; LlvmType
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005602"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%2B%3E"><span class="hs-operator hs-var">&lt;+&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot; is a unlowerable type, need a pointer&quot;</span></span><span>
</span><span id="line-245"></span><span>
</span><span id="line-246"></span><span class="hs-comment">-- | Lower a variable of 'LMPointer' type.</span><span>
</span><span id="line-247"></span><span class="annot"><a href="GHC.Llvm.Types.html#pVarLower"><span class="hs-identifier hs-type">pVarLower</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmVar"><span class="hs-identifier hs-type">LlvmVar</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmVar"><span class="hs-identifier hs-type">LlvmVar</span></a></span><span>
</span><span id="line-248"></span><span id="pVarLower"><span class="annot"><span class="annottext">pVarLower :: LlvmVar -&gt; LlvmVar
</span><a href="GHC.Llvm.Types.html#pVarLower"><span class="hs-identifier hs-var hs-var">pVarLower</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMGlobalVar"><span class="hs-identifier hs-type">LMGlobalVar</span></a></span><span> </span><span id="local-6989586621681005599"><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005599"><span class="hs-identifier hs-var">s</span></a></span></span><span> </span><span id="local-6989586621681005598"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005598"><span class="hs-identifier hs-var">t</span></a></span></span><span> </span><span id="local-6989586621681005597"><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="#local-6989586621681005597"><span class="hs-identifier hs-var">l</span></a></span></span><span> </span><span id="local-6989586621681005596"><span class="annot"><span class="annottext">LMSection
</span><a href="#local-6989586621681005596"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621681005595"><span class="annot"><span class="annottext">LMAlign
</span><a href="#local-6989586621681005595"><span class="hs-identifier hs-var">a</span></a></span></span><span> </span><span id="local-6989586621681005594"><span class="annot"><span class="annottext">LMConst
</span><a href="#local-6989586621681005594"><span class="hs-identifier hs-var">c</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">FastString
-&gt; LlvmType
-&gt; LlvmLinkageType
-&gt; LMSection
-&gt; LMAlign
-&gt; LMConst
-&gt; LlvmVar
</span><a href="GHC.Llvm.Types.html#LMGlobalVar"><span class="hs-identifier hs-var">LMGlobalVar</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005599"><span class="hs-identifier hs-var">s</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#pLower"><span class="hs-identifier hs-var">pLower</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005598"><span class="hs-identifier hs-var">t</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="#local-6989586621681005597"><span class="hs-identifier hs-var">l</span></a></span><span> </span><span class="annot"><span class="annottext">LMSection
</span><a href="#local-6989586621681005596"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">LMAlign
</span><a href="#local-6989586621681005595"><span class="hs-identifier hs-var">a</span></a></span><span> </span><span class="annot"><span class="annottext">LMConst
</span><a href="#local-6989586621681005594"><span class="hs-identifier hs-var">c</span></a></span><span>
</span><span id="line-249"></span><span class="annot"><a href="GHC.Llvm.Types.html#pVarLower"><span class="hs-identifier hs-var">pVarLower</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMLocalVar"><span class="hs-identifier hs-type">LMLocalVar</span></a></span><span>  </span><span id="local-6989586621681005593"><span class="annot"><span class="annottext">Unique
</span><a href="#local-6989586621681005593"><span class="hs-identifier hs-var">s</span></a></span></span><span> </span><span id="local-6989586621681005592"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005592"><span class="hs-identifier hs-var">t</span></a></span></span><span>        </span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Unique -&gt; LlvmType -&gt; LlvmVar
</span><a href="GHC.Llvm.Types.html#LMLocalVar"><span class="hs-identifier hs-var">LMLocalVar</span></a></span><span>  </span><span class="annot"><span class="annottext">Unique
</span><a href="#local-6989586621681005593"><span class="hs-identifier hs-var">s</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#pLower"><span class="hs-identifier hs-var">pLower</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005592"><span class="hs-identifier hs-var">t</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-250"></span><span class="annot"><a href="GHC.Llvm.Types.html#pVarLower"><span class="hs-identifier hs-var">pVarLower</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMNLocalVar"><span class="hs-identifier hs-type">LMNLocalVar</span></a></span><span> </span><span id="local-6989586621681005591"><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005591"><span class="hs-identifier hs-var">s</span></a></span></span><span> </span><span id="local-6989586621681005590"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005590"><span class="hs-identifier hs-var">t</span></a></span></span><span>        </span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">FastString -&gt; LlvmType -&gt; LlvmVar
</span><a href="GHC.Llvm.Types.html#LMNLocalVar"><span class="hs-identifier hs-var">LMNLocalVar</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005591"><span class="hs-identifier hs-var">s</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#pLower"><span class="hs-identifier hs-var">pLower</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005590"><span class="hs-identifier hs-var">t</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-251"></span><span class="annot"><a href="GHC.Llvm.Types.html#pVarLower"><span class="hs-identifier hs-var">pVarLower</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMLitVar"><span class="hs-identifier hs-type">LMLitVar</span></a></span><span>    </span><span class="annot"><span class="annottext">LlvmLit
</span><span class="hs-identifier">_</span></span><span>          </span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; LlvmVar
forall a. HasCallStack =&gt; String -&gt; a
</span><a href="../../base/src/GHC.Err.html#error"><span class="hs-identifier hs-var">error</span></a></span><span> </span><span class="annot"><span class="annottext">(String -&gt; LlvmVar) -&gt; String -&gt; LlvmVar
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;Can't lower a literal type!&quot;</span></span><span>
</span><span id="line-252"></span><span>
</span><span id="line-253"></span><span class="hs-comment">-- | Test if the given 'LlvmType' is an integer</span><span>
</span><span id="line-254"></span><span class="annot"><a href="GHC.Llvm.Types.html#isInt"><span class="hs-identifier hs-type">isInt</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-255"></span><span id="isInt"><span class="annot"><span class="annottext">isInt :: LlvmType -&gt; Bool
</span><a href="GHC.Llvm.Types.html#isInt"><span class="hs-identifier hs-var hs-var">isInt</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-type">LMInt</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-256"></span><span class="annot"><a href="GHC.Llvm.Types.html#isInt"><span class="hs-identifier hs-var">isInt</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span>         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-257"></span><span>
</span><span id="line-258"></span><span class="hs-comment">-- | Test if the given 'LlvmType' is a floating point type</span><span>
</span><span id="line-259"></span><span class="annot"><a href="GHC.Llvm.Types.html#isFloat"><span class="hs-identifier hs-type">isFloat</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-260"></span><span id="isFloat"><span class="annot"><span class="annottext">isFloat :: LlvmType -&gt; Bool
</span><a href="GHC.Llvm.Types.html#isFloat"><span class="hs-identifier hs-var hs-var">isFloat</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMFloat"><span class="hs-identifier hs-var">LMFloat</span></a></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-261"></span><span class="annot"><a href="GHC.Llvm.Types.html#isFloat"><span class="hs-identifier hs-var">isFloat</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMDouble"><span class="hs-identifier hs-var">LMDouble</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-262"></span><span class="annot"><a href="GHC.Llvm.Types.html#isFloat"><span class="hs-identifier hs-var">isFloat</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMFloat80"><span class="hs-identifier hs-var">LMFloat80</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-263"></span><span class="annot"><a href="GHC.Llvm.Types.html#isFloat"><span class="hs-identifier hs-var">isFloat</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMFloat128"><span class="hs-identifier hs-var">LMFloat128</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-264"></span><span class="annot"><a href="GHC.Llvm.Types.html#isFloat"><span class="hs-identifier hs-var">isFloat</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-265"></span><span>
</span><span id="line-266"></span><span class="hs-comment">-- | Test if the given 'LlvmType' is an 'LMPointer' construct</span><span>
</span><span id="line-267"></span><span class="annot"><a href="GHC.Llvm.Types.html#isPointer"><span class="hs-identifier hs-type">isPointer</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-268"></span><span id="isPointer"><span class="annot"><span class="annottext">isPointer :: LlvmType -&gt; Bool
</span><a href="GHC.Llvm.Types.html#isPointer"><span class="hs-identifier hs-var hs-var">isPointer</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMPointer"><span class="hs-identifier hs-type">LMPointer</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-269"></span><span class="annot"><a href="GHC.Llvm.Types.html#isPointer"><span class="hs-identifier hs-var">isPointer</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span>             </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-270"></span><span>
</span><span id="line-271"></span><span class="hs-comment">-- | Test if the given 'LlvmType' is an 'LMVector' construct</span><span>
</span><span id="line-272"></span><span class="annot"><a href="GHC.Llvm.Types.html#isVector"><span class="hs-identifier hs-type">isVector</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-273"></span><span id="isVector"><span class="annot"><span class="annottext">isVector :: LlvmType -&gt; Bool
</span><a href="GHC.Llvm.Types.html#isVector"><span class="hs-identifier hs-var hs-var">isVector</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMVector"><span class="hs-identifier hs-type">LMVector</span></a></span><span> </span><span class="hs-special">{</span><span class="hs-special">}</span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-274"></span><span class="annot"><a href="GHC.Llvm.Types.html#isVector"><span class="hs-identifier hs-var">isVector</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span>             </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-275"></span><span>
</span><span id="line-276"></span><span class="hs-comment">-- | Test if a 'LlvmVar' is global.</span><span>
</span><span id="line-277"></span><span class="annot"><a href="GHC.Llvm.Types.html#isGlobal"><span class="hs-identifier hs-type">isGlobal</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmVar"><span class="hs-identifier hs-type">LlvmVar</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span>
</span><span id="line-278"></span><span id="isGlobal"><span class="annot"><span class="annottext">isGlobal :: LlvmVar -&gt; Bool
</span><a href="GHC.Llvm.Types.html#isGlobal"><span class="hs-identifier hs-var hs-var">isGlobal</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMGlobalVar"><span class="hs-identifier hs-type">LMGlobalVar</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LMSection
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LMAlign
</span><span class="hs-identifier">_</span></span><span> </span><span class="annot"><span class="annottext">LMConst
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">True</span></span><span>
</span><span id="line-279"></span><span class="annot"><a href="GHC.Llvm.Types.html#isGlobal"><span class="hs-identifier hs-var">isGlobal</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmVar
</span><span class="hs-identifier">_</span></span><span>                         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span>
</span><span id="line-280"></span><span>
</span><span id="line-281"></span><span class="hs-comment">-- | Width in bits of an 'LlvmType', returns 0 if not applicable</span><span>
</span><span id="line-282"></span><span class="annot"><a href="GHC.Llvm.Types.html#llvmWidthInBits"><span class="hs-identifier hs-type">llvmWidthInBits</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../ghc-boot/src/GHC.Platform.html#Platform"><span class="hs-identifier hs-type">Platform</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span>
</span><span id="line-283"></span><span id="llvmWidthInBits"><span class="annot"><span class="annottext">llvmWidthInBits :: Platform -&gt; LlvmType -&gt; Int
</span><a href="GHC.Llvm.Types.html#llvmWidthInBits"><span class="hs-identifier hs-var hs-var">llvmWidthInBits</span></a></span></span><span> </span><span id="local-6989586621681005584"><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005584"><span class="hs-identifier hs-var">platform</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-glyph">\</span><span class="hs-glyph">case</span><span>
</span><span id="line-284"></span><span>   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-type">LMInt</span></a></span><span> </span><span id="local-6989586621681005583"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005583"><span class="hs-identifier hs-var">n</span></a></span></span><span class="hs-special">)</span><span>       </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005583"><span class="hs-identifier hs-var">n</span></a></span><span>
</span><span id="line-285"></span><span>   </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMFloat"><span class="hs-identifier hs-var">LMFloat</span></a></span><span class="hs-special">)</span><span>       </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">32</span></span><span>
</span><span id="line-286"></span><span>   </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMDouble"><span class="hs-identifier hs-var">LMDouble</span></a></span><span class="hs-special">)</span><span>      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">64</span></span><span>
</span><span id="line-287"></span><span>   </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMFloat80"><span class="hs-identifier hs-var">LMFloat80</span></a></span><span class="hs-special">)</span><span>     </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">80</span></span><span>
</span><span id="line-288"></span><span>   </span><span class="hs-special">(</span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMFloat128"><span class="hs-identifier hs-var">LMFloat128</span></a></span><span class="hs-special">)</span><span>    </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">128</span></span><span>
</span><span id="line-289"></span><span>   </span><span class="hs-comment">-- Could return either a pointer width here or the width of what</span><span>
</span><span id="line-290"></span><span>   </span><span class="hs-comment">-- it points to. We will go with the former for now.</span><span>
</span><span id="line-291"></span><span>   </span><span class="hs-comment">-- PMW: At least judging by the way LLVM outputs constants, pointers</span><span>
</span><span id="line-292"></span><span>   </span><span class="hs-comment">--      should use the former, but arrays the latter.</span><span>
</span><span id="line-293"></span><span>   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMPointer"><span class="hs-identifier hs-type">LMPointer</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span>   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Platform -&gt; LlvmType -&gt; Int
</span><a href="GHC.Llvm.Types.html#llvmWidthInBits"><span class="hs-identifier hs-var">llvmWidthInBits</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005584"><span class="hs-identifier hs-var">platform</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Platform -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#llvmWord"><span class="hs-identifier hs-var">llvmWord</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005584"><span class="hs-identifier hs-var">platform</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-294"></span><span>   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMArray"><span class="hs-identifier hs-type">LMArray</span></a></span><span> </span><span id="local-6989586621681005581"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005581"><span class="hs-identifier hs-var">n</span></a></span></span><span> </span><span id="local-6989586621681005580"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005580"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span>   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005581"><span class="hs-identifier hs-var">n</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Int
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2A"><span class="hs-operator hs-var">*</span></a></span><span> </span><span class="annot"><span class="annottext">Platform -&gt; LlvmType -&gt; Int
</span><a href="GHC.Llvm.Types.html#llvmWidthInBits"><span class="hs-identifier hs-var">llvmWidthInBits</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005584"><span class="hs-identifier hs-var">platform</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005580"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-295"></span><span>   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMVector"><span class="hs-identifier hs-type">LMVector</span></a></span><span> </span><span id="local-6989586621681005578"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005578"><span class="hs-identifier hs-var">n</span></a></span></span><span> </span><span id="local-6989586621681005577"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005577"><span class="hs-identifier hs-var">ty</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005578"><span class="hs-identifier hs-var">n</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Int
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2A"><span class="hs-operator hs-var">*</span></a></span><span> </span><span class="annot"><span class="annottext">Platform -&gt; LlvmType -&gt; Int
</span><a href="GHC.Llvm.Types.html#llvmWidthInBits"><span class="hs-identifier hs-var">llvmWidthInBits</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005584"><span class="hs-identifier hs-var">platform</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005577"><span class="hs-identifier hs-var">ty</span></a></span><span>
</span><span id="line-296"></span><span>   </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMLabel"><span class="hs-identifier hs-var">LMLabel</span></a></span><span>         </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">0</span></span><span>
</span><span id="line-297"></span><span>   </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMVoid"><span class="hs-identifier hs-var">LMVoid</span></a></span><span>          </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">0</span></span><span>
</span><span id="line-298"></span><span>   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMStruct"><span class="hs-identifier hs-type">LMStruct</span></a></span><span> </span><span id="local-6989586621681005576"><span class="annot"><span class="annottext">[LlvmType]
</span><a href="#local-6989586621681005576"><span class="hs-identifier hs-var">tys</span></a></span></span><span class="hs-special">)</span><span>  </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">[Int] -&gt; Int
forall (t :: * -&gt; *) a. (Foldable t, Num a) =&gt; t a -&gt; a
</span><a href="../../base/src/Data.Foldable.html#sum"><span class="hs-identifier hs-var">sum</span></a></span><span> </span><span class="annot"><span class="annottext">([Int] -&gt; Int) -&gt; [Int] -&gt; Int
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">(LlvmType -&gt; Int) -&gt; [LlvmType] -&gt; [Int]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Platform -&gt; LlvmType -&gt; Int
</span><a href="GHC.Llvm.Types.html#llvmWidthInBits"><span class="hs-identifier hs-var">llvmWidthInBits</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005584"><span class="hs-identifier hs-var">platform</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">[LlvmType]
</span><a href="#local-6989586621681005576"><span class="hs-identifier hs-var">tys</span></a></span><span>
</span><span id="line-299"></span><span>   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMStructU"><span class="hs-identifier hs-type">LMStructU</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmType]
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span>   </span><span class="hs-glyph">-&gt;</span><span>
</span><span id="line-300"></span><span>    </span><span class="hs-comment">-- It's not trivial to calculate the bit width of the unpacked structs,</span><span>
</span><span id="line-301"></span><span>    </span><span class="hs-comment">-- since they will be aligned depending on the specified datalayout (</span><span>
</span><span id="line-302"></span><span>    </span><span class="hs-comment">-- http://llvm.org/docs/LangRef.html#data-layout ). One way we could support</span><span>
</span><span id="line-303"></span><span>    </span><span class="hs-comment">-- this could be to make the GHC.CmmToLlvm.Ppr.moduleLayout be a data type</span><span>
</span><span id="line-304"></span><span>    </span><span class="hs-comment">-- that exposes the alignment information. However, currently the only place</span><span>
</span><span id="line-305"></span><span>    </span><span class="hs-comment">-- we use unpacked structs is LLVM intrinsics that return them (e.g.,</span><span>
</span><span id="line-306"></span><span>    </span><span class="hs-comment">-- llvm.sadd.with.overflow.*), so we don't actually need to compute their</span><span>
</span><span id="line-307"></span><span>    </span><span class="hs-comment">-- bit width.</span><span>
</span><span id="line-308"></span><span>    </span><span class="annot"><span class="annottext">String -&gt; Int
forall a. String -&gt; a
</span><a href="GHC.Utils.Panic.Plain.html#panic"><span class="hs-identifier hs-var">panic</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;llvmWidthInBits: not implemented for LMStructU&quot;</span></span><span>
</span><span id="line-309"></span><span>   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMFunction"><span class="hs-identifier hs-type">LMFunction</span></a></span><span>  </span><span class="annot"><span class="annottext">LlvmFunctionDecl
</span><span class="hs-identifier">_</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">0</span></span><span>
</span><span id="line-310"></span><span>   </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LMAlias"><span class="hs-identifier hs-type">LMAlias</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">FastString
</span><span class="hs-identifier">_</span></span><span class="hs-special">,</span><span id="local-6989586621681005574"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005574"><span class="hs-identifier hs-var">t</span></a></span></span><span class="hs-special">)</span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">Platform -&gt; LlvmType -&gt; Int
</span><a href="GHC.Llvm.Types.html#llvmWidthInBits"><span class="hs-identifier hs-var">llvmWidthInBits</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005584"><span class="hs-identifier hs-var">platform</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005574"><span class="hs-identifier hs-var">t</span></a></span><span>
</span><span id="line-311"></span><span>   </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#LMMetadata"><span class="hs-identifier hs-var">LMMetadata</span></a></span><span>      </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; Int
forall a. String -&gt; a
</span><a href="GHC.Utils.Panic.Plain.html#panic"><span class="hs-identifier hs-var">panic</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;llvmWidthInBits: Meta-data has no runtime representation!&quot;</span></span><span>
</span><span id="line-312"></span><span>
</span><span id="line-313"></span><span>
</span><span id="line-314"></span><span class="hs-comment">-- -----------------------------------------------------------------------------</span><span>
</span><span id="line-315"></span><span class="hs-comment">-- ** Shortcut for Common Types</span><span>
</span><span id="line-316"></span><span class="hs-comment">--</span><span>
</span><span id="line-317"></span><span>
</span><span id="line-318"></span><span class="annot"><a href="GHC.Llvm.Types.html#i128"><span class="hs-identifier hs-type">i128</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#i64"><span class="hs-identifier hs-type">i64</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#i32"><span class="hs-identifier hs-type">i32</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#i16"><span class="hs-identifier hs-type">i16</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#i8"><span class="hs-identifier hs-type">i8</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#i1"><span class="hs-identifier hs-type">i1</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#i8Ptr"><span class="hs-identifier hs-type">i8Ptr</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-319"></span><span id="i128"><span class="annot"><span class="annottext">i128 :: LlvmType
</span><a href="GHC.Llvm.Types.html#i128"><span class="hs-identifier hs-var hs-var">i128</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-var">LMInt</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">128</span></span><span>
</span><span id="line-320"></span><span id="i64"><span class="annot"><span class="annottext">i64 :: LlvmType
</span><a href="GHC.Llvm.Types.html#i64"><span class="hs-identifier hs-var hs-var">i64</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-var">LMInt</span></a></span><span>  </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">64</span></span><span>
</span><span id="line-321"></span><span id="i32"><span class="annot"><span class="annottext">i32 :: LlvmType
</span><a href="GHC.Llvm.Types.html#i32"><span class="hs-identifier hs-var hs-var">i32</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-var">LMInt</span></a></span><span>  </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">32</span></span><span>
</span><span id="line-322"></span><span id="i16"><span class="annot"><span class="annottext">i16 :: LlvmType
</span><a href="GHC.Llvm.Types.html#i16"><span class="hs-identifier hs-var hs-var">i16</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-var">LMInt</span></a></span><span>  </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">16</span></span><span>
</span><span id="line-323"></span><span id="i8"><span class="annot"><span class="annottext">i8 :: LlvmType
</span><a href="GHC.Llvm.Types.html#i8"><span class="hs-identifier hs-var hs-var">i8</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-var">LMInt</span></a></span><span>   </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">8</span></span><span>
</span><span id="line-324"></span><span id="i1"><span class="annot"><span class="annottext">i1 :: LlvmType
</span><a href="GHC.Llvm.Types.html#i1"><span class="hs-identifier hs-var hs-var">i1</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-var">LMInt</span></a></span><span>   </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">1</span></span><span>
</span><span id="line-325"></span><span id="i8Ptr"><span class="annot"><span class="annottext">i8Ptr :: LlvmType
</span><a href="GHC.Llvm.Types.html#i8Ptr"><span class="hs-identifier hs-var hs-var">i8Ptr</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#pLift"><span class="hs-identifier hs-var">pLift</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="GHC.Llvm.Types.html#i8"><span class="hs-identifier hs-var">i8</span></a></span><span>
</span><span id="line-326"></span><span>
</span><span id="line-327"></span><span class="hs-comment">-- | The target architectures word size</span><span>
</span><span id="line-328"></span><span class="annot"><a href="GHC.Llvm.Types.html#llvmWord"><span class="hs-identifier hs-type">llvmWord</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#llvmWordPtr"><span class="hs-identifier hs-type">llvmWordPtr</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../ghc-boot/src/GHC.Platform.html#Platform"><span class="hs-identifier hs-type">Platform</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span>
</span><span id="line-329"></span><span id="llvmWord"><span class="annot"><span class="annottext">llvmWord :: Platform -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#llvmWord"><span class="hs-identifier hs-var hs-var">llvmWord</span></a></span></span><span>    </span><span id="local-6989586621681005565"><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005565"><span class="hs-identifier hs-var">platform</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Int -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#LMInt"><span class="hs-identifier hs-var">LMInt</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Platform -&gt; Int
</span><a href="../../ghc-boot/src/GHC.Platform.html#platformWordSizeInBytes"><span class="hs-identifier hs-var">platformWordSizeInBytes</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005565"><span class="hs-identifier hs-var">platform</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; Int -&gt; Int
forall a. Num a =&gt; a -&gt; a -&gt; a
</span><a href="../../base/src/GHC.Num.html#%2A"><span class="hs-operator hs-var">*</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">8</span></span><span class="hs-special">)</span><span>
</span><span id="line-330"></span><span id="llvmWordPtr"><span class="annot"><span class="annottext">llvmWordPtr :: Platform -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#llvmWordPtr"><span class="hs-identifier hs-var hs-var">llvmWordPtr</span></a></span></span><span> </span><span id="local-6989586621681005563"><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005563"><span class="hs-identifier hs-var">platform</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#pLift"><span class="hs-identifier hs-var">pLift</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Platform -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#llvmWord"><span class="hs-identifier hs-var">llvmWord</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005563"><span class="hs-identifier hs-var">platform</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-331"></span><span>
</span><span id="line-332"></span><span class="hs-comment">-- -----------------------------------------------------------------------------</span><span>
</span><span id="line-333"></span><span class="hs-comment">-- * LLVM Function Types</span><span>
</span><span id="line-334"></span><span class="hs-comment">--</span><span>
</span><span id="line-335"></span><span>
</span><span id="line-336"></span><span class="hs-comment">-- | An LLVM Function</span><span>
</span><span id="line-337"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmFunctionDecl"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmFunctionDecl"><span class="hs-identifier hs-var">LlvmFunctionDecl</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span id="LlvmFunctionDecl"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmFunctionDecl"><span class="hs-identifier hs-var">LlvmFunctionDecl</span></a></span></span><span> </span><span class="hs-special">{</span><span>
</span><span id="line-338"></span><span>        </span><span class="hs-comment">-- | Unique identifier of the function</span><span>
</span><span id="line-339"></span><span>        </span><span id="decName"><span class="annot"><span class="annottext">LlvmFunctionDecl -&gt; FastString
</span><a href="GHC.Llvm.Types.html#decName"><span class="hs-identifier hs-var hs-var">decName</span></a></span></span><span>       </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LMString"><span class="hs-identifier hs-type">LMString</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-340"></span><span>        </span><span class="hs-comment">-- | LinkageType of the function</span><span>
</span><span id="line-341"></span><span>        </span><span id="funcLinkage"><span class="annot"><span class="annottext">LlvmFunctionDecl -&gt; LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#funcLinkage"><span class="hs-identifier hs-var hs-var">funcLinkage</span></a></span></span><span>   </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLinkageType"><span class="hs-identifier hs-type">LlvmLinkageType</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-342"></span><span>        </span><span class="hs-comment">-- | The calling convention of the function</span><span>
</span><span id="line-343"></span><span>        </span><span id="funcCc"><span class="annot"><span class="annottext">LlvmFunctionDecl -&gt; LlvmCallConvention
</span><a href="GHC.Llvm.Types.html#funcCc"><span class="hs-identifier hs-var hs-var">funcCc</span></a></span></span><span>        </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmCallConvention"><span class="hs-identifier hs-type">LlvmCallConvention</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-344"></span><span>        </span><span class="hs-comment">-- | Type of the returned value</span><span>
</span><span id="line-345"></span><span>        </span><span id="decReturnType"><span class="annot"><span class="annottext">LlvmFunctionDecl -&gt; LlvmType
</span><a href="GHC.Llvm.Types.html#decReturnType"><span class="hs-identifier hs-var hs-var">decReturnType</span></a></span></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-346"></span><span>        </span><span class="hs-comment">-- | Indicates if this function uses varargs</span><span>
</span><span id="line-347"></span><span>        </span><span id="decVarargs"><span class="annot"><span class="annottext">LlvmFunctionDecl -&gt; LlvmParameterListType
</span><a href="GHC.Llvm.Types.html#decVarargs"><span class="hs-identifier hs-var hs-var">decVarargs</span></a></span></span><span>    </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmParameterListType"><span class="hs-identifier hs-type">LlvmParameterListType</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-348"></span><span>        </span><span class="hs-comment">-- | Parameter types and attributes</span><span>
</span><span id="line-349"></span><span>        </span><span id="decParams"><span class="annot"><span class="annottext">LlvmFunctionDecl -&gt; [LlvmParameter]
</span><a href="GHC.Llvm.Types.html#decParams"><span class="hs-identifier hs-var hs-var">decParams</span></a></span></span><span>     </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmParameter"><span class="hs-identifier hs-type">LlvmParameter</span></a></span><span class="hs-special">]</span><span class="hs-special">,</span><span>
</span><span id="line-350"></span><span>        </span><span class="hs-comment">-- | Function align value, must be power of 2</span><span>
</span><span id="line-351"></span><span>        </span><span id="funcAlign"><span class="annot"><span class="annottext">LlvmFunctionDecl -&gt; LMAlign
</span><a href="GHC.Llvm.Types.html#funcAlign"><span class="hs-identifier hs-var hs-var">funcAlign</span></a></span></span><span>     </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LMAlign"><span class="hs-identifier hs-type">LMAlign</span></a></span><span>
</span><span id="line-352"></span><span>  </span><span class="hs-special">}</span><span>
</span><span id="line-353"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005543"><span id="local-6989586621681005554"><span class="annot"><span class="annottext">LlvmFunctionDecl -&gt; LlvmFunctionDecl -&gt; Bool
(LlvmFunctionDecl -&gt; LlvmFunctionDecl -&gt; Bool)
-&gt; (LlvmFunctionDecl -&gt; LlvmFunctionDecl -&gt; Bool)
-&gt; Eq LlvmFunctionDecl
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmFunctionDecl -&gt; LlvmFunctionDecl -&gt; Bool
$c/= :: LlvmFunctionDecl -&gt; LlvmFunctionDecl -&gt; Bool
== :: LlvmFunctionDecl -&gt; LlvmFunctionDecl -&gt; Bool
$c== :: LlvmFunctionDecl -&gt; LlvmFunctionDecl -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-354"></span><span>
</span><span id="line-355"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621681005538"><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmFunctionDecl"><span class="hs-identifier hs-type">LlvmFunctionDecl</span></a></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-356"></span><span>  </span><span id="local-6989586621681005534"><span class="annot"><span class="annottext">ppr :: LlvmFunctionDecl -&gt; SDoc
</span><a href="#local-6989586621681005534"><span class="hs-identifier hs-var hs-var hs-var hs-var">ppr</span></a></span></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmFunctionDecl"><span class="hs-identifier hs-type">LlvmFunctionDecl</span></a></span><span> </span><span id="local-6989586621681005533"><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005533"><span class="hs-identifier hs-var">n</span></a></span></span><span> </span><span id="local-6989586621681005532"><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="#local-6989586621681005532"><span class="hs-identifier hs-var">l</span></a></span></span><span> </span><span id="local-6989586621681005531"><span class="annot"><span class="annottext">LlvmCallConvention
</span><a href="#local-6989586621681005531"><span class="hs-identifier hs-var">c</span></a></span></span><span> </span><span id="local-6989586621681005530"><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005530"><span class="hs-identifier hs-var">r</span></a></span></span><span> </span><span id="local-6989586621681005529"><span class="annot"><span class="annottext">LlvmParameterListType
</span><a href="#local-6989586621681005529"><span class="hs-identifier hs-var">varg</span></a></span></span><span> </span><span id="local-6989586621681005528"><span class="annot"><span class="annottext">[LlvmParameter]
</span><a href="#local-6989586621681005528"><span class="hs-identifier hs-var">p</span></a></span></span><span> </span><span id="local-6989586621681005527"><span class="annot"><span class="annottext">LMAlign
</span><a href="#local-6989586621681005527"><span class="hs-identifier hs-var">a</span></a></span></span><span class="hs-special">)</span><span>
</span><span id="line-357"></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621681005525"><span class="annot"><span class="annottext">align :: SDoc
</span><a href="#local-6989586621681005525"><span class="hs-identifier hs-var hs-var">align</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">LMAlign
</span><a href="#local-6989586621681005527"><span class="hs-identifier hs-var">a</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-358"></span><span>                       </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Just"><span class="hs-identifier hs-type">Just</span></a></span><span> </span><span id="local-6989586621681005524"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005524"><span class="hs-identifier hs-var">a'</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot; align &quot;</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005524"><span class="hs-identifier hs-var">a'</span></a></span><span>
</span><span id="line-359"></span><span>                       </span><span class="annot"><span class="annottext">LMAlign
</span><a href="../../base/src/GHC.Maybe.html#Nothing"><span class="hs-identifier hs-var">Nothing</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">SDoc
</span><a href="GHC.Utils.Outputable.html#empty"><span class="hs-identifier hs-var">empty</span></a></span><span>
</span><span id="line-360"></span><span>      </span><span class="hs-keyword">in</span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="#local-6989586621681005532"><span class="hs-identifier hs-var">l</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%2B%3E"><span class="hs-operator hs-var">&lt;+&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCallConvention -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCallConvention
</span><a href="#local-6989586621681005531"><span class="hs-identifier hs-var">c</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%2B%3E"><span class="hs-operator hs-var">&lt;+&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmType
</span><a href="#local-6989586621681005530"><span class="hs-identifier hs-var">r</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%2B%3E"><span class="hs-operator hs-var">&lt;+&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#char"><span class="hs-identifier hs-var">char</span></a></span><span> </span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'@'</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">FastString -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ftext"><span class="hs-identifier hs-var">ftext</span></a></span><span> </span><span class="annot"><span class="annottext">FastString
</span><a href="#local-6989586621681005533"><span class="hs-identifier hs-var">n</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span>
</span><span id="line-361"></span><span>             </span><span class="annot"><span class="annottext">SDoc
</span><a href="GHC.Utils.Outputable.html#lparen"><span class="hs-identifier hs-var">lparen</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParameterListType -&gt; [LlvmParameter] -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppParams"><span class="hs-identifier hs-var">ppParams</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParameterListType
</span><a href="#local-6989586621681005529"><span class="hs-identifier hs-var">varg</span></a></span><span> </span><span class="annot"><span class="annottext">[LlvmParameter]
</span><a href="#local-6989586621681005528"><span class="hs-identifier hs-var">p</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc
</span><a href="GHC.Utils.Outputable.html#rparen"><span class="hs-identifier hs-var">rparen</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc
</span><a href="#local-6989586621681005525"><span class="hs-identifier hs-var">align</span></a></span><span>
</span><span id="line-362"></span><span>
</span><span id="line-363"></span><span class="hs-keyword">type</span><span> </span><span id="LlvmFunctionDecls"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmFunctionDecls"><span class="hs-identifier hs-var">LlvmFunctionDecls</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmFunctionDecl"><span class="hs-identifier hs-type">LlvmFunctionDecl</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-364"></span><span>
</span><span id="line-365"></span><span class="hs-keyword">type</span><span> </span><span id="LlvmParameter"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmParameter"><span class="hs-identifier hs-var">LlvmParameter</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmType"><span class="hs-identifier hs-type">LlvmType</span></a></span><span class="hs-special">,</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmParamAttr"><span class="hs-identifier hs-type">LlvmParamAttr</span></a></span><span class="hs-special">]</span><span class="hs-special">)</span><span>
</span><span id="line-366"></span><span>
</span><span id="line-367"></span><span class="hs-comment">-- | LLVM Parameter Attributes.</span><span>
</span><span id="line-368"></span><span class="hs-comment">--</span><span>
</span><span id="line-369"></span><span class="hs-comment">-- Parameter attributes are used to communicate additional information about</span><span>
</span><span id="line-370"></span><span class="hs-comment">-- the result or parameters of a function</span><span>
</span><span id="line-371"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmParamAttr"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmParamAttr"><span class="hs-identifier hs-var">LlvmParamAttr</span></a></span></span><span>
</span><span id="line-372"></span><span>  </span><span class="hs-comment">-- | This indicates to the code generator that the parameter or return value</span><span>
</span><span id="line-373"></span><span>  </span><span class="hs-comment">-- should be zero-extended to a 32-bit value by the caller (for a parameter)</span><span>
</span><span id="line-374"></span><span>  </span><span class="hs-comment">-- or the callee (for a return value).</span><span>
</span><span id="line-375"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="ZeroExt"><span class="annot"><a href="GHC.Llvm.Types.html#ZeroExt"><span class="hs-identifier hs-var">ZeroExt</span></a></span></span><span>
</span><span id="line-376"></span><span>  </span><span class="hs-comment">-- | This indicates to the code generator that the parameter or return value</span><span>
</span><span id="line-377"></span><span>  </span><span class="hs-comment">-- should be sign-extended to a 32-bit value by the caller (for a parameter)</span><span>
</span><span id="line-378"></span><span>  </span><span class="hs-comment">-- or the callee (for a return value).</span><span>
</span><span id="line-379"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="SignExt"><span class="annot"><a href="GHC.Llvm.Types.html#SignExt"><span class="hs-identifier hs-var">SignExt</span></a></span></span><span>
</span><span id="line-380"></span><span>  </span><span class="hs-comment">-- | This indicates that this parameter or return value should be treated in</span><span>
</span><span id="line-381"></span><span>  </span><span class="hs-comment">-- a special target-dependent fashion during while emitting code for a</span><span>
</span><span id="line-382"></span><span>  </span><span class="hs-comment">-- function call or return (usually, by putting it in a register as opposed</span><span>
</span><span id="line-383"></span><span>  </span><span class="hs-comment">-- to memory).</span><span>
</span><span id="line-384"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="InReg"><span class="annot"><a href="GHC.Llvm.Types.html#InReg"><span class="hs-identifier hs-var">InReg</span></a></span></span><span>
</span><span id="line-385"></span><span>  </span><span class="hs-comment">-- | This indicates that the pointer parameter should really be passed by</span><span>
</span><span id="line-386"></span><span>  </span><span class="hs-comment">-- value to the function.</span><span>
</span><span id="line-387"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="ByVal"><span class="annot"><a href="GHC.Llvm.Types.html#ByVal"><span class="hs-identifier hs-var">ByVal</span></a></span></span><span>
</span><span id="line-388"></span><span>  </span><span class="hs-comment">-- | This indicates that the pointer parameter specifies the address of a</span><span>
</span><span id="line-389"></span><span>  </span><span class="hs-comment">-- structure that is the return value of the function in the source program.</span><span>
</span><span id="line-390"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="SRet"><span class="annot"><a href="GHC.Llvm.Types.html#SRet"><span class="hs-identifier hs-var">SRet</span></a></span></span><span>
</span><span id="line-391"></span><span>  </span><span class="hs-comment">-- | This indicates that the pointer does not alias any global or any other</span><span>
</span><span id="line-392"></span><span>  </span><span class="hs-comment">-- parameter.</span><span>
</span><span id="line-393"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="NoAlias"><span class="annot"><a href="GHC.Llvm.Types.html#NoAlias"><span class="hs-identifier hs-var">NoAlias</span></a></span></span><span>
</span><span id="line-394"></span><span>  </span><span class="hs-comment">-- | This indicates that the callee does not make any copies of the pointer</span><span>
</span><span id="line-395"></span><span>  </span><span class="hs-comment">-- that outlive the callee itself</span><span>
</span><span id="line-396"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="NoCapture"><span class="annot"><a href="GHC.Llvm.Types.html#NoCapture"><span class="hs-identifier hs-var">NoCapture</span></a></span></span><span>
</span><span id="line-397"></span><span>  </span><span class="hs-comment">-- | This indicates that the pointer parameter can be excised using the</span><span>
</span><span id="line-398"></span><span>  </span><span class="hs-comment">-- trampoline intrinsics.</span><span>
</span><span id="line-399"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="Nest"><span class="annot"><a href="GHC.Llvm.Types.html#Nest"><span class="hs-identifier hs-var">Nest</span></a></span></span><span>
</span><span id="line-400"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005510"><span id="local-6989586621681005512"><span class="annot"><span class="annottext">LlvmParamAttr -&gt; LlvmParamAttr -&gt; Bool
(LlvmParamAttr -&gt; LlvmParamAttr -&gt; Bool)
-&gt; (LlvmParamAttr -&gt; LlvmParamAttr -&gt; Bool) -&gt; Eq LlvmParamAttr
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmParamAttr -&gt; LlvmParamAttr -&gt; Bool
$c/= :: LlvmParamAttr -&gt; LlvmParamAttr -&gt; Bool
== :: LlvmParamAttr -&gt; LlvmParamAttr -&gt; Bool
$c== :: LlvmParamAttr -&gt; LlvmParamAttr -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-401"></span><span>
</span><span id="line-402"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621681005507"><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmParamAttr"><span class="hs-identifier hs-type">LlvmParamAttr</span></a></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-403"></span><span>  </span><span id="local-6989586621681005506"><span class="annot"><span class="annottext">ppr :: LlvmParamAttr -&gt; SDoc
</span><a href="#local-6989586621681005506"><span class="hs-identifier hs-var hs-var hs-var hs-var">ppr</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmParamAttr
</span><a href="GHC.Llvm.Types.html#ZeroExt"><span class="hs-identifier hs-var">ZeroExt</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;zeroext&quot;</span></span><span>
</span><span id="line-404"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParamAttr
</span><a href="GHC.Llvm.Types.html#SignExt"><span class="hs-identifier hs-var">SignExt</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;signext&quot;</span></span><span>
</span><span id="line-405"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParamAttr
</span><a href="GHC.Llvm.Types.html#InReg"><span class="hs-identifier hs-var">InReg</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;inreg&quot;</span></span><span>
</span><span id="line-406"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParamAttr
</span><a href="GHC.Llvm.Types.html#ByVal"><span class="hs-identifier hs-var">ByVal</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;byval&quot;</span></span><span>
</span><span id="line-407"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParamAttr
</span><a href="GHC.Llvm.Types.html#SRet"><span class="hs-identifier hs-var">SRet</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;sret&quot;</span></span><span>
</span><span id="line-408"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParamAttr
</span><a href="GHC.Llvm.Types.html#NoAlias"><span class="hs-identifier hs-var">NoAlias</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;noalias&quot;</span></span><span>
</span><span id="line-409"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParamAttr
</span><a href="GHC.Llvm.Types.html#NoCapture"><span class="hs-identifier hs-var">NoCapture</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;nocapture&quot;</span></span><span>
</span><span id="line-410"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmParamAttr
</span><a href="GHC.Llvm.Types.html#Nest"><span class="hs-identifier hs-var">Nest</span></a></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;nest&quot;</span></span><span>
</span><span id="line-411"></span><span>
</span><span id="line-412"></span><span class="hs-comment">-- | Llvm Function Attributes.</span><span>
</span><span id="line-413"></span><span class="hs-comment">--</span><span>
</span><span id="line-414"></span><span class="hs-comment">-- Function attributes are set to communicate additional information about a</span><span>
</span><span id="line-415"></span><span class="hs-comment">-- function. Function attributes are considered to be part of the function,</span><span>
</span><span id="line-416"></span><span class="hs-comment">-- not of the function type, so functions with different parameter attributes</span><span>
</span><span id="line-417"></span><span class="hs-comment">-- can have the same function type. Functions can have multiple attributes.</span><span>
</span><span id="line-418"></span><span class="hs-comment">--</span><span>
</span><span id="line-419"></span><span class="hs-comment">-- Descriptions taken from &lt;http://llvm.org/docs/LangRef.html#fnattrs&gt;</span><span>
</span><span id="line-420"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmFuncAttr"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmFuncAttr"><span class="hs-identifier hs-var">LlvmFuncAttr</span></a></span></span><span>
</span><span id="line-421"></span><span>  </span><span class="hs-comment">-- | This attribute indicates that the inliner should attempt to inline this</span><span>
</span><span id="line-422"></span><span>  </span><span class="hs-comment">-- function into callers whenever possible, ignoring any active inlining</span><span>
</span><span id="line-423"></span><span>  </span><span class="hs-comment">-- size threshold for this caller.</span><span>
</span><span id="line-424"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="AlwaysInline"><span class="annot"><a href="GHC.Llvm.Types.html#AlwaysInline"><span class="hs-identifier hs-var">AlwaysInline</span></a></span></span><span>
</span><span id="line-425"></span><span>  </span><span class="hs-comment">-- | This attribute indicates that the source code contained a hint that</span><span>
</span><span id="line-426"></span><span>  </span><span class="hs-comment">-- inlining this function is desirable (such as the \&quot;inline\&quot; keyword in</span><span>
</span><span id="line-427"></span><span>  </span><span class="hs-comment">-- C/C++). It is just a hint; it imposes no requirements on the inliner.</span><span>
</span><span id="line-428"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="InlineHint"><span class="annot"><a href="GHC.Llvm.Types.html#InlineHint"><span class="hs-identifier hs-var">InlineHint</span></a></span></span><span>
</span><span id="line-429"></span><span>  </span><span class="hs-comment">-- | This attribute indicates that the inliner should never inline this</span><span>
</span><span id="line-430"></span><span>  </span><span class="hs-comment">-- function in any situation. This attribute may not be used together</span><span>
</span><span id="line-431"></span><span>  </span><span class="hs-comment">-- with the alwaysinline attribute.</span><span>
</span><span id="line-432"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="NoInline"><span class="annot"><a href="GHC.Llvm.Types.html#NoInline"><span class="hs-identifier hs-var">NoInline</span></a></span></span><span>
</span><span id="line-433"></span><span>  </span><span class="hs-comment">-- | This attribute suggests that optimization passes and code generator</span><span>
</span><span id="line-434"></span><span>  </span><span class="hs-comment">-- passes make choices that keep the code size of this function low, and</span><span>
</span><span id="line-435"></span><span>  </span><span class="hs-comment">-- otherwise do optimizations specifically to reduce code size.</span><span>
</span><span id="line-436"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="OptSize"><span class="annot"><a href="GHC.Llvm.Types.html#OptSize"><span class="hs-identifier hs-var">OptSize</span></a></span></span><span>
</span><span id="line-437"></span><span>  </span><span class="hs-comment">-- | This function attribute indicates that the function never returns</span><span>
</span><span id="line-438"></span><span>  </span><span class="hs-comment">-- normally. This produces undefined behavior at runtime if the function</span><span>
</span><span id="line-439"></span><span>  </span><span class="hs-comment">-- ever does dynamically return.</span><span>
</span><span id="line-440"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="NoReturn"><span class="annot"><a href="GHC.Llvm.Types.html#NoReturn"><span class="hs-identifier hs-var">NoReturn</span></a></span></span><span>
</span><span id="line-441"></span><span>  </span><span class="hs-comment">-- | This function attribute indicates that the function never returns with</span><span>
</span><span id="line-442"></span><span>  </span><span class="hs-comment">-- an unwind or exceptional control flow. If the function does unwind, its</span><span>
</span><span id="line-443"></span><span>  </span><span class="hs-comment">-- runtime behavior is undefined.</span><span>
</span><span id="line-444"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="NoUnwind"><span class="annot"><a href="GHC.Llvm.Types.html#NoUnwind"><span class="hs-identifier hs-var">NoUnwind</span></a></span></span><span>
</span><span id="line-445"></span><span>  </span><span class="hs-comment">-- | This attribute indicates that the function computes its result (or</span><span>
</span><span id="line-446"></span><span>  </span><span class="hs-comment">-- decides to unwind an exception) based strictly on its arguments, without</span><span>
</span><span id="line-447"></span><span>  </span><span class="hs-comment">-- dereferencing any pointer arguments or otherwise accessing any mutable</span><span>
</span><span id="line-448"></span><span>  </span><span class="hs-comment">-- state (e.g. memory, control registers, etc) visible to caller functions.</span><span>
</span><span id="line-449"></span><span>  </span><span class="hs-comment">-- It does not write through any pointer arguments (including byval</span><span>
</span><span id="line-450"></span><span>  </span><span class="hs-comment">-- arguments) and never changes any state visible to callers. This means</span><span>
</span><span id="line-451"></span><span>  </span><span class="hs-comment">-- that it cannot unwind exceptions by calling the C++ exception throwing</span><span>
</span><span id="line-452"></span><span>  </span><span class="hs-comment">-- methods, but could use the unwind instruction.</span><span>
</span><span id="line-453"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="ReadNone"><span class="annot"><a href="GHC.Llvm.Types.html#ReadNone"><span class="hs-identifier hs-var">ReadNone</span></a></span></span><span>
</span><span id="line-454"></span><span>  </span><span class="hs-comment">-- | This attribute indicates that the function does not write through any</span><span>
</span><span id="line-455"></span><span>  </span><span class="hs-comment">-- pointer arguments (including byval arguments) or otherwise modify any</span><span>
</span><span id="line-456"></span><span>  </span><span class="hs-comment">-- state (e.g. memory, control registers, etc) visible to caller functions.</span><span>
</span><span id="line-457"></span><span>  </span><span class="hs-comment">-- It may dereference pointer arguments and read state that may be set in</span><span>
</span><span id="line-458"></span><span>  </span><span class="hs-comment">-- the caller. A readonly function always returns the same value (or unwinds</span><span>
</span><span id="line-459"></span><span>  </span><span class="hs-comment">-- an exception identically) when called with the same set of arguments and</span><span>
</span><span id="line-460"></span><span>  </span><span class="hs-comment">-- global state. It cannot unwind an exception by calling the C++ exception</span><span>
</span><span id="line-461"></span><span>  </span><span class="hs-comment">-- throwing methods, but may use the unwind instruction.</span><span>
</span><span id="line-462"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="ReadOnly"><span class="annot"><a href="GHC.Llvm.Types.html#ReadOnly"><span class="hs-identifier hs-var">ReadOnly</span></a></span></span><span>
</span><span id="line-463"></span><span>  </span><span class="hs-comment">-- | This attribute indicates that the function should emit a stack smashing</span><span>
</span><span id="line-464"></span><span>  </span><span class="hs-comment">-- protector. It is in the form of a \&quot;canary\&quot;&#8212;a random value placed on the</span><span>
</span><span id="line-465"></span><span>  </span><span class="hs-comment">-- stack before the local variables that's checked upon return from the</span><span>
</span><span id="line-466"></span><span>  </span><span class="hs-comment">-- function to see if it has been overwritten. A heuristic is used to</span><span>
</span><span id="line-467"></span><span>  </span><span class="hs-comment">-- determine if a function needs stack protectors or not.</span><span>
</span><span id="line-468"></span><span>  </span><span class="hs-comment">--</span><span>
</span><span id="line-469"></span><span>  </span><span class="hs-comment">-- If a function that has an ssp attribute is inlined into a function that</span><span>
</span><span id="line-470"></span><span>  </span><span class="hs-comment">-- doesn't have an ssp attribute, then the resulting function will have an</span><span>
</span><span id="line-471"></span><span>  </span><span class="hs-comment">-- ssp attribute.</span><span>
</span><span id="line-472"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="Ssp"><span class="annot"><a href="GHC.Llvm.Types.html#Ssp"><span class="hs-identifier hs-var">Ssp</span></a></span></span><span>
</span><span id="line-473"></span><span>  </span><span class="hs-comment">-- | This attribute indicates that the function should always emit a stack</span><span>
</span><span id="line-474"></span><span>  </span><span class="hs-comment">-- smashing protector. This overrides the ssp function attribute.</span><span>
</span><span id="line-475"></span><span>  </span><span class="hs-comment">--</span><span>
</span><span id="line-476"></span><span>  </span><span class="hs-comment">-- If a function that has an sspreq attribute is inlined into a function</span><span>
</span><span id="line-477"></span><span>  </span><span class="hs-comment">-- that doesn't have an sspreq attribute or which has an ssp attribute,</span><span>
</span><span id="line-478"></span><span>  </span><span class="hs-comment">-- then the resulting function will have an sspreq attribute.</span><span>
</span><span id="line-479"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="SspReq"><span class="annot"><a href="GHC.Llvm.Types.html#SspReq"><span class="hs-identifier hs-var">SspReq</span></a></span></span><span>
</span><span id="line-480"></span><span>  </span><span class="hs-comment">-- | This attribute indicates that the code generator should not use a red</span><span>
</span><span id="line-481"></span><span>  </span><span class="hs-comment">-- zone, even if the target-specific ABI normally permits it.</span><span>
</span><span id="line-482"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="NoRedZone"><span class="annot"><a href="GHC.Llvm.Types.html#NoRedZone"><span class="hs-identifier hs-var">NoRedZone</span></a></span></span><span>
</span><span id="line-483"></span><span>  </span><span class="hs-comment">-- | This attributes disables implicit floating point instructions.</span><span>
</span><span id="line-484"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="NoImplicitFloat"><span class="annot"><a href="GHC.Llvm.Types.html#NoImplicitFloat"><span class="hs-identifier hs-var">NoImplicitFloat</span></a></span></span><span>
</span><span id="line-485"></span><span>  </span><span class="hs-comment">-- | This attribute disables prologue / epilogue emission for the function.</span><span>
</span><span id="line-486"></span><span>  </span><span class="hs-comment">-- This can have very system-specific consequences.</span><span>
</span><span id="line-487"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="Naked"><span class="annot"><a href="GHC.Llvm.Types.html#Naked"><span class="hs-identifier hs-var">Naked</span></a></span></span><span>
</span><span id="line-488"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005489"><span id="local-6989586621681005491"><span class="annot"><span class="annottext">LlvmFuncAttr -&gt; LlvmFuncAttr -&gt; Bool
(LlvmFuncAttr -&gt; LlvmFuncAttr -&gt; Bool)
-&gt; (LlvmFuncAttr -&gt; LlvmFuncAttr -&gt; Bool) -&gt; Eq LlvmFuncAttr
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmFuncAttr -&gt; LlvmFuncAttr -&gt; Bool
$c/= :: LlvmFuncAttr -&gt; LlvmFuncAttr -&gt; Bool
== :: LlvmFuncAttr -&gt; LlvmFuncAttr -&gt; Bool
$c== :: LlvmFuncAttr -&gt; LlvmFuncAttr -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-489"></span><span>
</span><span id="line-490"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621681005486"><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmFuncAttr"><span class="hs-identifier hs-type">LlvmFuncAttr</span></a></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-491"></span><span>  </span><span id="local-6989586621681005485"><span class="annot"><span class="annottext">ppr :: LlvmFuncAttr -&gt; SDoc
</span><a href="#local-6989586621681005485"><span class="hs-identifier hs-var hs-var hs-var hs-var">ppr</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#AlwaysInline"><span class="hs-identifier hs-var">AlwaysInline</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;alwaysinline&quot;</span></span><span>
</span><span id="line-492"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#InlineHint"><span class="hs-identifier hs-var">InlineHint</span></a></span><span>         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;inlinehint&quot;</span></span><span>
</span><span id="line-493"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#NoInline"><span class="hs-identifier hs-var">NoInline</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;noinline&quot;</span></span><span>
</span><span id="line-494"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#OptSize"><span class="hs-identifier hs-var">OptSize</span></a></span><span>            </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;optsize&quot;</span></span><span>
</span><span id="line-495"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#NoReturn"><span class="hs-identifier hs-var">NoReturn</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;noreturn&quot;</span></span><span>
</span><span id="line-496"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#NoUnwind"><span class="hs-identifier hs-var">NoUnwind</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;nounwind&quot;</span></span><span>
</span><span id="line-497"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#ReadNone"><span class="hs-identifier hs-var">ReadNone</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;readnone&quot;</span></span><span>
</span><span id="line-498"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#ReadOnly"><span class="hs-identifier hs-var">ReadOnly</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;readonly&quot;</span></span><span>
</span><span id="line-499"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#Ssp"><span class="hs-identifier hs-var">Ssp</span></a></span><span>                </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ssp&quot;</span></span><span>
</span><span id="line-500"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#SspReq"><span class="hs-identifier hs-var">SspReq</span></a></span><span>             </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ssqreq&quot;</span></span><span>
</span><span id="line-501"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#NoRedZone"><span class="hs-identifier hs-var">NoRedZone</span></a></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;noredzone&quot;</span></span><span>
</span><span id="line-502"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#NoImplicitFloat"><span class="hs-identifier hs-var">NoImplicitFloat</span></a></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;noimplicitfloat&quot;</span></span><span>
</span><span id="line-503"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmFuncAttr
</span><a href="GHC.Llvm.Types.html#Naked"><span class="hs-identifier hs-var">Naked</span></a></span><span>              </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;naked&quot;</span></span><span>
</span><span id="line-504"></span><span>
</span><span id="line-505"></span><span>
</span><span id="line-506"></span><span class="hs-comment">-- | Different types to call a function.</span><span>
</span><span id="line-507"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmCallType"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmCallType"><span class="hs-identifier hs-var">LlvmCallType</span></a></span></span><span>
</span><span id="line-508"></span><span>  </span><span class="hs-comment">-- | Normal call, allocate a new stack frame.</span><span>
</span><span id="line-509"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="StdCall"><span class="annot"><a href="GHC.Llvm.Types.html#StdCall"><span class="hs-identifier hs-var">StdCall</span></a></span></span><span>
</span><span id="line-510"></span><span>  </span><span class="hs-comment">-- | Tail call, perform the call in the current stack frame.</span><span>
</span><span id="line-511"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="TailCall"><span class="annot"><a href="GHC.Llvm.Types.html#TailCall"><span class="hs-identifier hs-var">TailCall</span></a></span></span><span>
</span><span id="line-512"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005479"><span id="local-6989586621681005481"><span class="annot"><span class="annottext">LlvmCallType -&gt; LlvmCallType -&gt; Bool
(LlvmCallType -&gt; LlvmCallType -&gt; Bool)
-&gt; (LlvmCallType -&gt; LlvmCallType -&gt; Bool) -&gt; Eq LlvmCallType
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmCallType -&gt; LlvmCallType -&gt; Bool
$c/= :: LlvmCallType -&gt; LlvmCallType -&gt; Bool
== :: LlvmCallType -&gt; LlvmCallType -&gt; Bool
$c== :: LlvmCallType -&gt; LlvmCallType -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">,</span><span id="local-6989586621681005473"><span id="local-6989586621681005475"><span id="local-6989586621681005477"><span class="annot"><span class="annottext">Int -&gt; LlvmCallType -&gt; ShowS
[LlvmCallType] -&gt; ShowS
LlvmCallType -&gt; String
(Int -&gt; LlvmCallType -&gt; ShowS)
-&gt; (LlvmCallType -&gt; String)
-&gt; ([LlvmCallType] -&gt; ShowS)
-&gt; Show LlvmCallType
forall a.
(Int -&gt; a -&gt; ShowS) -&gt; (a -&gt; String) -&gt; ([a] -&gt; ShowS) -&gt; Show a
showList :: [LlvmCallType] -&gt; ShowS
$cshowList :: [LlvmCallType] -&gt; ShowS
show :: LlvmCallType -&gt; String
$cshow :: LlvmCallType -&gt; String
showsPrec :: Int -&gt; LlvmCallType -&gt; ShowS
$cshowsPrec :: Int -&gt; LlvmCallType -&gt; ShowS
</span><a href="../../base/src/GHC.Show.html#Show"><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Show</span></a></span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-513"></span><span>
</span><span id="line-514"></span><span class="hs-comment">-- | Different calling conventions a function can use.</span><span>
</span><span id="line-515"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmCallConvention"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmCallConvention"><span class="hs-identifier hs-var">LlvmCallConvention</span></a></span></span><span>
</span><span id="line-516"></span><span>  </span><span class="hs-comment">-- | The C calling convention.</span><span>
</span><span id="line-517"></span><span>  </span><span class="hs-comment">-- This calling convention (the default if no other calling convention is</span><span>
</span><span id="line-518"></span><span>  </span><span class="hs-comment">-- specified) matches the target C calling conventions. This calling</span><span>
</span><span id="line-519"></span><span>  </span><span class="hs-comment">-- convention supports varargs function calls and tolerates some mismatch in</span><span>
</span><span id="line-520"></span><span>  </span><span class="hs-comment">-- the declared prototype and implemented declaration of the function (as</span><span>
</span><span id="line-521"></span><span>  </span><span class="hs-comment">-- does normal C).</span><span>
</span><span id="line-522"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="CC_Ccc"><span class="annot"><a href="GHC.Llvm.Types.html#CC_Ccc"><span class="hs-identifier hs-var">CC_Ccc</span></a></span></span><span>
</span><span id="line-523"></span><span>  </span><span class="hs-comment">-- | This calling convention attempts to make calls as fast as possible</span><span>
</span><span id="line-524"></span><span>  </span><span class="hs-comment">-- (e.g. by passing things in registers). This calling convention allows</span><span>
</span><span id="line-525"></span><span>  </span><span class="hs-comment">-- the target to use whatever tricks it wants to produce fast code for the</span><span>
</span><span id="line-526"></span><span>  </span><span class="hs-comment">-- target, without having to conform to an externally specified ABI</span><span>
</span><span id="line-527"></span><span>  </span><span class="hs-comment">-- (Application Binary Interface). Implementations of this convention should</span><span>
</span><span id="line-528"></span><span>  </span><span class="hs-comment">-- allow arbitrary tail call optimization to be supported. This calling</span><span>
</span><span id="line-529"></span><span>  </span><span class="hs-comment">-- convention does not support varargs and requires the prototype of al</span><span>
</span><span id="line-530"></span><span>  </span><span class="hs-comment">-- callees to exactly match the prototype of the function definition.</span><span>
</span><span id="line-531"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="CC_Fastcc"><span class="annot"><a href="GHC.Llvm.Types.html#CC_Fastcc"><span class="hs-identifier hs-var">CC_Fastcc</span></a></span></span><span>
</span><span id="line-532"></span><span>  </span><span class="hs-comment">-- | This calling convention attempts to make code in the caller as efficient</span><span>
</span><span id="line-533"></span><span>  </span><span class="hs-comment">-- as possible under the assumption that the call is not commonly executed.</span><span>
</span><span id="line-534"></span><span>  </span><span class="hs-comment">-- As such, these calls often preserve all registers so that the call does</span><span>
</span><span id="line-535"></span><span>  </span><span class="hs-comment">-- not break any live ranges in the caller side. This calling convention</span><span>
</span><span id="line-536"></span><span>  </span><span class="hs-comment">-- does not support varargs and requires the prototype of all callees to</span><span>
</span><span id="line-537"></span><span>  </span><span class="hs-comment">-- exactly match the prototype of the function definition.</span><span>
</span><span id="line-538"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="CC_Coldcc"><span class="annot"><a href="GHC.Llvm.Types.html#CC_Coldcc"><span class="hs-identifier hs-var">CC_Coldcc</span></a></span></span><span>
</span><span id="line-539"></span><span>  </span><span class="hs-comment">-- | The GHC-specific 'registerised' calling convention.</span><span>
</span><span id="line-540"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="CC_Ghc"><span class="annot"><a href="GHC.Llvm.Types.html#CC_Ghc"><span class="hs-identifier hs-var">CC_Ghc</span></a></span></span><span>
</span><span id="line-541"></span><span>  </span><span class="hs-comment">-- | Any calling convention may be specified by number, allowing</span><span>
</span><span id="line-542"></span><span>  </span><span class="hs-comment">-- target-specific calling conventions to be used. Target specific calling</span><span>
</span><span id="line-543"></span><span>  </span><span class="hs-comment">-- conventions start at 64.</span><span>
</span><span id="line-544"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="CC_Ncc"><span class="annot"><a href="GHC.Llvm.Types.html#CC_Ncc"><span class="hs-identifier hs-var">CC_Ncc</span></a></span></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span>
</span><span id="line-545"></span><span>  </span><span class="hs-comment">-- | X86 Specific 'StdCall' convention. LLVM includes a specific alias for it</span><span>
</span><span id="line-546"></span><span>  </span><span class="hs-comment">-- rather than just using CC_Ncc.</span><span>
</span><span id="line-547"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="CC_X86_Stdcc"><span class="annot"><a href="GHC.Llvm.Types.html#CC_X86_Stdcc"><span class="hs-identifier hs-var">CC_X86_Stdcc</span></a></span></span><span>
</span><span id="line-548"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005461"><span id="local-6989586621681005464"><span class="annot"><span class="annottext">LlvmCallConvention -&gt; LlvmCallConvention -&gt; Bool
(LlvmCallConvention -&gt; LlvmCallConvention -&gt; Bool)
-&gt; (LlvmCallConvention -&gt; LlvmCallConvention -&gt; Bool)
-&gt; Eq LlvmCallConvention
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmCallConvention -&gt; LlvmCallConvention -&gt; Bool
$c/= :: LlvmCallConvention -&gt; LlvmCallConvention -&gt; Bool
== :: LlvmCallConvention -&gt; LlvmCallConvention -&gt; Bool
$c== :: LlvmCallConvention -&gt; LlvmCallConvention -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-549"></span><span>
</span><span id="line-550"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621681005458"><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmCallConvention"><span class="hs-identifier hs-type">LlvmCallConvention</span></a></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-551"></span><span>  </span><span id="local-6989586621681005456"><span class="annot"><span class="annottext">ppr :: LlvmCallConvention -&gt; SDoc
</span><a href="#local-6989586621681005456"><span class="hs-identifier hs-var hs-var hs-var hs-var">ppr</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmCallConvention
</span><a href="GHC.Llvm.Types.html#CC_Ccc"><span class="hs-identifier hs-var">CC_Ccc</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ccc&quot;</span></span><span>
</span><span id="line-552"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCallConvention
</span><a href="GHC.Llvm.Types.html#CC_Fastcc"><span class="hs-identifier hs-var">CC_Fastcc</span></a></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;fastcc&quot;</span></span><span>
</span><span id="line-553"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCallConvention
</span><a href="GHC.Llvm.Types.html#CC_Coldcc"><span class="hs-identifier hs-var">CC_Coldcc</span></a></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;coldcc&quot;</span></span><span>
</span><span id="line-554"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCallConvention
</span><a href="GHC.Llvm.Types.html#CC_Ghc"><span class="hs-identifier hs-var">CC_Ghc</span></a></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ghccc&quot;</span></span><span>
</span><span id="line-555"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Llvm.Types.html#CC_Ncc"><span class="hs-identifier hs-type">CC_Ncc</span></a></span><span> </span><span id="local-6989586621681005455"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005455"><span class="hs-identifier hs-var">i</span></a></span></span><span class="hs-special">)</span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;cc &quot;</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621681005455"><span class="hs-identifier hs-var">i</span></a></span><span>
</span><span id="line-556"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCallConvention
</span><a href="GHC.Llvm.Types.html#CC_X86_Stdcc"><span class="hs-identifier hs-var">CC_X86_Stdcc</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;x86_stdcallcc&quot;</span></span><span>
</span><span id="line-557"></span><span>
</span><span id="line-558"></span><span>
</span><span id="line-559"></span><span class="hs-comment">-- | Functions can have a fixed amount of parameters, or a variable amount.</span><span>
</span><span id="line-560"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmParameterListType"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmParameterListType"><span class="hs-identifier hs-var">LlvmParameterListType</span></a></span></span><span>
</span><span id="line-561"></span><span>  </span><span class="hs-comment">-- Fixed amount of arguments.</span><span>
</span><span id="line-562"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="FixedArgs"><span class="annot"><a href="GHC.Llvm.Types.html#FixedArgs"><span class="hs-identifier hs-var">FixedArgs</span></a></span></span><span>
</span><span id="line-563"></span><span>  </span><span class="hs-comment">-- Variable amount of arguments.</span><span>
</span><span id="line-564"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="VarArgs"><span class="annot"><a href="GHC.Llvm.Types.html#VarArgs"><span class="hs-identifier hs-var">VarArgs</span></a></span></span><span>
</span><span id="line-565"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005450"><span id="local-6989586621681005452"><span class="annot"><span class="annottext">LlvmParameterListType -&gt; LlvmParameterListType -&gt; Bool
(LlvmParameterListType -&gt; LlvmParameterListType -&gt; Bool)
-&gt; (LlvmParameterListType -&gt; LlvmParameterListType -&gt; Bool)
-&gt; Eq LlvmParameterListType
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmParameterListType -&gt; LlvmParameterListType -&gt; Bool
$c/= :: LlvmParameterListType -&gt; LlvmParameterListType -&gt; Bool
== :: LlvmParameterListType -&gt; LlvmParameterListType -&gt; Bool
$c== :: LlvmParameterListType -&gt; LlvmParameterListType -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">,</span><span id="local-6989586621681005444"><span id="local-6989586621681005446"><span id="local-6989586621681005448"><span class="annot"><span class="annottext">Int -&gt; LlvmParameterListType -&gt; ShowS
[LlvmParameterListType] -&gt; ShowS
LlvmParameterListType -&gt; String
(Int -&gt; LlvmParameterListType -&gt; ShowS)
-&gt; (LlvmParameterListType -&gt; String)
-&gt; ([LlvmParameterListType] -&gt; ShowS)
-&gt; Show LlvmParameterListType
forall a.
(Int -&gt; a -&gt; ShowS) -&gt; (a -&gt; String) -&gt; ([a] -&gt; ShowS) -&gt; Show a
showList :: [LlvmParameterListType] -&gt; ShowS
$cshowList :: [LlvmParameterListType] -&gt; ShowS
show :: LlvmParameterListType -&gt; String
$cshow :: LlvmParameterListType -&gt; String
showsPrec :: Int -&gt; LlvmParameterListType -&gt; ShowS
$cshowsPrec :: Int -&gt; LlvmParameterListType -&gt; ShowS
</span><a href="../../base/src/GHC.Show.html#Show"><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var hs-var hs-var">Show</span></a></span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-566"></span><span>
</span><span id="line-567"></span><span>
</span><span id="line-568"></span><span class="hs-comment">-- | Linkage type of a symbol.</span><span>
</span><span id="line-569"></span><span class="hs-comment">--</span><span>
</span><span id="line-570"></span><span class="hs-comment">-- The description of the constructors is copied from the Llvm Assembly Language</span><span>
</span><span id="line-571"></span><span class="hs-comment">-- Reference Manual &lt;http://www.llvm.org/docs/LangRef.html#linkage&gt;, because</span><span>
</span><span id="line-572"></span><span class="hs-comment">-- they correspond to the Llvm linkage types.</span><span>
</span><span id="line-573"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmLinkageType"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLinkageType"><span class="hs-identifier hs-var">LlvmLinkageType</span></a></span></span><span>
</span><span id="line-574"></span><span>  </span><span class="hs-comment">-- | Global values with internal linkage are only directly accessible by</span><span>
</span><span id="line-575"></span><span>  </span><span class="hs-comment">-- objects in the current module. In particular, linking code into a module</span><span>
</span><span id="line-576"></span><span>  </span><span class="hs-comment">-- with an internal global value may cause the internal to be renamed as</span><span>
</span><span id="line-577"></span><span>  </span><span class="hs-comment">-- necessary to avoid collisions. Because the symbol is internal to the</span><span>
</span><span id="line-578"></span><span>  </span><span class="hs-comment">-- module, all references can be updated. This corresponds to the notion</span><span>
</span><span id="line-579"></span><span>  </span><span class="hs-comment">-- of the @static@ keyword in C.</span><span>
</span><span id="line-580"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="Internal"><span class="annot"><a href="GHC.Llvm.Types.html#Internal"><span class="hs-identifier hs-var">Internal</span></a></span></span><span>
</span><span id="line-581"></span><span>  </span><span class="hs-comment">-- | Globals with @linkonce@ linkage are merged with other globals of the</span><span>
</span><span id="line-582"></span><span>  </span><span class="hs-comment">-- same name when linkage occurs. This is typically used to implement</span><span>
</span><span id="line-583"></span><span>  </span><span class="hs-comment">-- inline functions, templates, or other code which must be generated</span><span>
</span><span id="line-584"></span><span>  </span><span class="hs-comment">-- in each translation unit that uses it. Unreferenced linkonce globals are</span><span>
</span><span id="line-585"></span><span>  </span><span class="hs-comment">-- allowed to be discarded.</span><span>
</span><span id="line-586"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LinkOnce"><span class="annot"><a href="GHC.Llvm.Types.html#LinkOnce"><span class="hs-identifier hs-var">LinkOnce</span></a></span></span><span>
</span><span id="line-587"></span><span>  </span><span class="hs-comment">-- | @weak@ linkage is exactly the same as linkonce linkage, except that</span><span>
</span><span id="line-588"></span><span>  </span><span class="hs-comment">-- unreferenced weak globals may not be discarded. This is used for globals</span><span>
</span><span id="line-589"></span><span>  </span><span class="hs-comment">-- that may be emitted in multiple translation units, but that are not</span><span>
</span><span id="line-590"></span><span>  </span><span class="hs-comment">-- guaranteed to be emitted into every translation unit that uses them. One</span><span>
</span><span id="line-591"></span><span>  </span><span class="hs-comment">-- example of this are common globals in C, such as @int X;@ at global</span><span>
</span><span id="line-592"></span><span>  </span><span class="hs-comment">-- scope.</span><span>
</span><span id="line-593"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="Weak"><span class="annot"><a href="GHC.Llvm.Types.html#Weak"><span class="hs-identifier hs-var">Weak</span></a></span></span><span>
</span><span id="line-594"></span><span>  </span><span class="hs-comment">-- | @appending@ linkage may only be applied to global variables of pointer</span><span>
</span><span id="line-595"></span><span>  </span><span class="hs-comment">-- to array type. When two global variables with appending linkage are</span><span>
</span><span id="line-596"></span><span>  </span><span class="hs-comment">-- linked together, the two global arrays are appended together. This is</span><span>
</span><span id="line-597"></span><span>  </span><span class="hs-comment">-- the Llvm, typesafe, equivalent of having the system linker append</span><span>
</span><span id="line-598"></span><span>  </span><span class="hs-comment">-- together @sections@ with identical names when .o files are linked.</span><span>
</span><span id="line-599"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="Appending"><span class="annot"><a href="GHC.Llvm.Types.html#Appending"><span class="hs-identifier hs-var">Appending</span></a></span></span><span>
</span><span id="line-600"></span><span>  </span><span class="hs-comment">-- | The semantics of this linkage follow the ELF model: the symbol is weak</span><span>
</span><span id="line-601"></span><span>  </span><span class="hs-comment">-- until linked, if not linked, the symbol becomes null instead of being an</span><span>
</span><span id="line-602"></span><span>  </span><span class="hs-comment">-- undefined reference.</span><span>
</span><span id="line-603"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="ExternWeak"><span class="annot"><a href="GHC.Llvm.Types.html#ExternWeak"><span class="hs-identifier hs-var">ExternWeak</span></a></span></span><span>
</span><span id="line-604"></span><span>  </span><span class="hs-comment">-- | The symbol participates in linkage and can be used to resolve external</span><span>
</span><span id="line-605"></span><span>  </span><span class="hs-comment">--  symbol references.</span><span>
</span><span id="line-606"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="ExternallyVisible"><span class="annot"><a href="GHC.Llvm.Types.html#ExternallyVisible"><span class="hs-identifier hs-var">ExternallyVisible</span></a></span></span><span>
</span><span id="line-607"></span><span>  </span><span class="hs-comment">-- | Alias for 'ExternallyVisible' but with explicit textual form in LLVM</span><span>
</span><span id="line-608"></span><span>  </span><span class="hs-comment">--  assembly.</span><span>
</span><span id="line-609"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="External"><span class="annot"><a href="GHC.Llvm.Types.html#External"><span class="hs-identifier hs-var">External</span></a></span></span><span>
</span><span id="line-610"></span><span>  </span><span class="hs-comment">-- | Symbol is private to the module and should not appear in the symbol table</span><span>
</span><span id="line-611"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="Private"><span class="annot"><a href="GHC.Llvm.Types.html#Private"><span class="hs-identifier hs-var">Private</span></a></span></span><span>
</span><span id="line-612"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005433"><span id="local-6989586621681005435"><span class="annot"><span class="annottext">LlvmLinkageType -&gt; LlvmLinkageType -&gt; Bool
(LlvmLinkageType -&gt; LlvmLinkageType -&gt; Bool)
-&gt; (LlvmLinkageType -&gt; LlvmLinkageType -&gt; Bool)
-&gt; Eq LlvmLinkageType
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmLinkageType -&gt; LlvmLinkageType -&gt; Bool
$c/= :: LlvmLinkageType -&gt; LlvmLinkageType -&gt; Bool
== :: LlvmLinkageType -&gt; LlvmLinkageType -&gt; Bool
$c== :: LlvmLinkageType -&gt; LlvmLinkageType -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-613"></span><span>
</span><span id="line-614"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621681005430"><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmLinkageType"><span class="hs-identifier hs-type">LlvmLinkageType</span></a></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-615"></span><span>  </span><span id="local-6989586621681005429"><span class="annot"><span class="annottext">ppr :: LlvmLinkageType -&gt; SDoc
</span><a href="#local-6989586621681005429"><span class="hs-identifier hs-var hs-var hs-var hs-var">ppr</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#Internal"><span class="hs-identifier hs-var">Internal</span></a></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;internal&quot;</span></span><span>
</span><span id="line-616"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#LinkOnce"><span class="hs-identifier hs-var">LinkOnce</span></a></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;linkonce&quot;</span></span><span>
</span><span id="line-617"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#Weak"><span class="hs-identifier hs-var">Weak</span></a></span><span>              </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;weak&quot;</span></span><span>
</span><span id="line-618"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#Appending"><span class="hs-identifier hs-var">Appending</span></a></span><span>         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;appending&quot;</span></span><span>
</span><span id="line-619"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#ExternWeak"><span class="hs-identifier hs-var">ExternWeak</span></a></span><span>        </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;extern_weak&quot;</span></span><span>
</span><span id="line-620"></span><span>  </span><span class="hs-comment">-- ExternallyVisible does not have a textual representation, it is</span><span>
</span><span id="line-621"></span><span>  </span><span class="hs-comment">-- the linkage type a function resolves to if no other is specified</span><span>
</span><span id="line-622"></span><span>  </span><span class="hs-comment">-- in Llvm.</span><span>
</span><span id="line-623"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#ExternallyVisible"><span class="hs-identifier hs-var">ExternallyVisible</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">SDoc
</span><a href="GHC.Utils.Outputable.html#empty"><span class="hs-identifier hs-var">empty</span></a></span><span>
</span><span id="line-624"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#External"><span class="hs-identifier hs-var">External</span></a></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;external&quot;</span></span><span>
</span><span id="line-625"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmLinkageType
</span><a href="GHC.Llvm.Types.html#Private"><span class="hs-identifier hs-var">Private</span></a></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;private&quot;</span></span><span>
</span><span id="line-626"></span><span>
</span><span id="line-627"></span><span class="hs-comment">-- -----------------------------------------------------------------------------</span><span>
</span><span id="line-628"></span><span class="hs-comment">-- * LLVM Operations</span><span>
</span><span id="line-629"></span><span class="hs-comment">--</span><span>
</span><span id="line-630"></span><span>
</span><span id="line-631"></span><span class="hs-comment">-- | Llvm binary operators machine operations.</span><span>
</span><span id="line-632"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmMachOp"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmMachOp"><span class="hs-identifier hs-var">LlvmMachOp</span></a></span></span><span>
</span><span id="line-633"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="LM_MO_Add"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_Add"><span class="hs-identifier hs-var">LM_MO_Add</span></a></span></span><span>  </span><span class="hs-comment">-- ^ add two integer, floating point or vector values.</span><span>
</span><span id="line-634"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_Sub"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_Sub"><span class="hs-identifier hs-var">LM_MO_Sub</span></a></span></span><span>  </span><span class="hs-comment">-- ^ subtract two ...</span><span>
</span><span id="line-635"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_Mul"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_Mul"><span class="hs-identifier hs-var">LM_MO_Mul</span></a></span></span><span>  </span><span class="hs-comment">-- ^ multiply ..</span><span>
</span><span id="line-636"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_UDiv"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_UDiv"><span class="hs-identifier hs-var">LM_MO_UDiv</span></a></span></span><span> </span><span class="hs-comment">-- ^ unsigned integer or vector division.</span><span>
</span><span id="line-637"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_SDiv"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_SDiv"><span class="hs-identifier hs-var">LM_MO_SDiv</span></a></span></span><span> </span><span class="hs-comment">-- ^ signed integer ..</span><span>
</span><span id="line-638"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_URem"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_URem"><span class="hs-identifier hs-var">LM_MO_URem</span></a></span></span><span> </span><span class="hs-comment">-- ^ unsigned integer or vector remainder (mod)</span><span>
</span><span id="line-639"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_SRem"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_SRem"><span class="hs-identifier hs-var">LM_MO_SRem</span></a></span></span><span> </span><span class="hs-comment">-- ^ signed ...</span><span>
</span><span id="line-640"></span><span>
</span><span id="line-641"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_FAdd"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_FAdd"><span class="hs-identifier hs-var">LM_MO_FAdd</span></a></span></span><span> </span><span class="hs-comment">-- ^ add two floating point or vector values.</span><span>
</span><span id="line-642"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_FSub"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_FSub"><span class="hs-identifier hs-var">LM_MO_FSub</span></a></span></span><span> </span><span class="hs-comment">-- ^ subtract two ...</span><span>
</span><span id="line-643"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_FMul"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_FMul"><span class="hs-identifier hs-var">LM_MO_FMul</span></a></span></span><span> </span><span class="hs-comment">-- ^ multiply ...</span><span>
</span><span id="line-644"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_FDiv"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_FDiv"><span class="hs-identifier hs-var">LM_MO_FDiv</span></a></span></span><span> </span><span class="hs-comment">-- ^ divide ...</span><span>
</span><span id="line-645"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_FRem"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_FRem"><span class="hs-identifier hs-var">LM_MO_FRem</span></a></span></span><span> </span><span class="hs-comment">-- ^ remainder ...</span><span>
</span><span id="line-646"></span><span>
</span><span id="line-647"></span><span>  </span><span class="hs-comment">-- | Left shift</span><span>
</span><span id="line-648"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_Shl"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_Shl"><span class="hs-identifier hs-var">LM_MO_Shl</span></a></span></span><span>
</span><span id="line-649"></span><span>  </span><span class="hs-comment">-- | Logical shift right</span><span>
</span><span id="line-650"></span><span>  </span><span class="hs-comment">-- Shift right, filling with zero</span><span>
</span><span id="line-651"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_LShr"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_LShr"><span class="hs-identifier hs-var">LM_MO_LShr</span></a></span></span><span>
</span><span id="line-652"></span><span>  </span><span class="hs-comment">-- | Arithmetic shift right</span><span>
</span><span id="line-653"></span><span>  </span><span class="hs-comment">-- The most significant bits of the result will be equal to the sign bit of</span><span>
</span><span id="line-654"></span><span>  </span><span class="hs-comment">-- the left operand.</span><span>
</span><span id="line-655"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_AShr"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_AShr"><span class="hs-identifier hs-var">LM_MO_AShr</span></a></span></span><span>
</span><span id="line-656"></span><span>
</span><span id="line-657"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_And"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_And"><span class="hs-identifier hs-var">LM_MO_And</span></a></span></span><span> </span><span class="hs-comment">-- ^ AND bitwise logical operation.</span><span>
</span><span id="line-658"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_Or"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_Or"><span class="hs-identifier hs-var">LM_MO_Or</span></a></span></span><span>  </span><span class="hs-comment">-- ^ OR bitwise logical operation.</span><span>
</span><span id="line-659"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_MO_Xor"><span class="annot"><a href="GHC.Llvm.Types.html#LM_MO_Xor"><span class="hs-identifier hs-var">LM_MO_Xor</span></a></span></span><span> </span><span class="hs-comment">-- ^ XOR bitwise logical operation.</span><span>
</span><span id="line-660"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005407"><span id="local-6989586621681005409"><span class="annot"><span class="annottext">LlvmMachOp -&gt; LlvmMachOp -&gt; Bool
(LlvmMachOp -&gt; LlvmMachOp -&gt; Bool)
-&gt; (LlvmMachOp -&gt; LlvmMachOp -&gt; Bool) -&gt; Eq LlvmMachOp
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmMachOp -&gt; LlvmMachOp -&gt; Bool
$c/= :: LlvmMachOp -&gt; LlvmMachOp -&gt; Bool
== :: LlvmMachOp -&gt; LlvmMachOp -&gt; Bool
$c== :: LlvmMachOp -&gt; LlvmMachOp -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-661"></span><span>
</span><span id="line-662"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621681005404"><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmMachOp"><span class="hs-identifier hs-type">LlvmMachOp</span></a></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-663"></span><span>  </span><span id="local-6989586621681005403"><span class="annot"><span class="annottext">ppr :: LlvmMachOp -&gt; SDoc
</span><a href="#local-6989586621681005403"><span class="hs-identifier hs-var hs-var hs-var hs-var">ppr</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_Add"><span class="hs-identifier hs-var">LM_MO_Add</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;add&quot;</span></span><span>
</span><span id="line-664"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_Sub"><span class="hs-identifier hs-var">LM_MO_Sub</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;sub&quot;</span></span><span>
</span><span id="line-665"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_Mul"><span class="hs-identifier hs-var">LM_MO_Mul</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;mul&quot;</span></span><span>
</span><span id="line-666"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_UDiv"><span class="hs-identifier hs-var">LM_MO_UDiv</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;udiv&quot;</span></span><span>
</span><span id="line-667"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_SDiv"><span class="hs-identifier hs-var">LM_MO_SDiv</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;sdiv&quot;</span></span><span>
</span><span id="line-668"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_URem"><span class="hs-identifier hs-var">LM_MO_URem</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;urem&quot;</span></span><span>
</span><span id="line-669"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_SRem"><span class="hs-identifier hs-var">LM_MO_SRem</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;srem&quot;</span></span><span>
</span><span id="line-670"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_FAdd"><span class="hs-identifier hs-var">LM_MO_FAdd</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;fadd&quot;</span></span><span>
</span><span id="line-671"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_FSub"><span class="hs-identifier hs-var">LM_MO_FSub</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;fsub&quot;</span></span><span>
</span><span id="line-672"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_FMul"><span class="hs-identifier hs-var">LM_MO_FMul</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;fmul&quot;</span></span><span>
</span><span id="line-673"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_FDiv"><span class="hs-identifier hs-var">LM_MO_FDiv</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;fdiv&quot;</span></span><span>
</span><span id="line-674"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_FRem"><span class="hs-identifier hs-var">LM_MO_FRem</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;frem&quot;</span></span><span>
</span><span id="line-675"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_Shl"><span class="hs-identifier hs-var">LM_MO_Shl</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;shl&quot;</span></span><span>
</span><span id="line-676"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_LShr"><span class="hs-identifier hs-var">LM_MO_LShr</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;lshr&quot;</span></span><span>
</span><span id="line-677"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_AShr"><span class="hs-identifier hs-var">LM_MO_AShr</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ashr&quot;</span></span><span>
</span><span id="line-678"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_And"><span class="hs-identifier hs-var">LM_MO_And</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;and&quot;</span></span><span>
</span><span id="line-679"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_Or"><span class="hs-identifier hs-var">LM_MO_Or</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;or&quot;</span></span><span>
</span><span id="line-680"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmMachOp
</span><a href="GHC.Llvm.Types.html#LM_MO_Xor"><span class="hs-identifier hs-var">LM_MO_Xor</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;xor&quot;</span></span><span>
</span><span id="line-681"></span><span>
</span><span id="line-682"></span><span>
</span><span id="line-683"></span><span class="hs-comment">-- | Llvm compare operations.</span><span>
</span><span id="line-684"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmCmpOp"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmCmpOp"><span class="hs-identifier hs-var">LlvmCmpOp</span></a></span></span><span>
</span><span id="line-685"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="LM_CMP_Eq"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Eq"><span class="hs-identifier hs-var">LM_CMP_Eq</span></a></span></span><span>  </span><span class="hs-comment">-- ^ Equal (Signed and Unsigned)</span><span>
</span><span id="line-686"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Ne"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Ne"><span class="hs-identifier hs-var">LM_CMP_Ne</span></a></span></span><span>  </span><span class="hs-comment">-- ^ Not equal (Signed and Unsigned)</span><span>
</span><span id="line-687"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Ugt"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Ugt"><span class="hs-identifier hs-var">LM_CMP_Ugt</span></a></span></span><span> </span><span class="hs-comment">-- ^ Unsigned greater than</span><span>
</span><span id="line-688"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Uge"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Uge"><span class="hs-identifier hs-var">LM_CMP_Uge</span></a></span></span><span> </span><span class="hs-comment">-- ^ Unsigned greater than or equal</span><span>
</span><span id="line-689"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Ult"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Ult"><span class="hs-identifier hs-var">LM_CMP_Ult</span></a></span></span><span> </span><span class="hs-comment">-- ^ Unsigned less than</span><span>
</span><span id="line-690"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Ule"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Ule"><span class="hs-identifier hs-var">LM_CMP_Ule</span></a></span></span><span> </span><span class="hs-comment">-- ^ Unsigned less than or equal</span><span>
</span><span id="line-691"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Sgt"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Sgt"><span class="hs-identifier hs-var">LM_CMP_Sgt</span></a></span></span><span> </span><span class="hs-comment">-- ^ Signed greater than</span><span>
</span><span id="line-692"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Sge"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Sge"><span class="hs-identifier hs-var">LM_CMP_Sge</span></a></span></span><span> </span><span class="hs-comment">-- ^ Signed greater than or equal</span><span>
</span><span id="line-693"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Slt"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Slt"><span class="hs-identifier hs-var">LM_CMP_Slt</span></a></span></span><span> </span><span class="hs-comment">-- ^ Signed less than</span><span>
</span><span id="line-694"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Sle"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Sle"><span class="hs-identifier hs-var">LM_CMP_Sle</span></a></span></span><span> </span><span class="hs-comment">-- ^ Signed less than or equal</span><span>
</span><span id="line-695"></span><span>
</span><span id="line-696"></span><span>  </span><span class="hs-comment">-- Float comparisons. GHC uses a mix of ordered and unordered float</span><span>
</span><span id="line-697"></span><span>  </span><span class="hs-comment">-- comparisons.</span><span>
</span><span id="line-698"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Feq"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Feq"><span class="hs-identifier hs-var">LM_CMP_Feq</span></a></span></span><span> </span><span class="hs-comment">-- ^ Float equal</span><span>
</span><span id="line-699"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Fne"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Fne"><span class="hs-identifier hs-var">LM_CMP_Fne</span></a></span></span><span> </span><span class="hs-comment">-- ^ Float not equal</span><span>
</span><span id="line-700"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Fgt"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Fgt"><span class="hs-identifier hs-var">LM_CMP_Fgt</span></a></span></span><span> </span><span class="hs-comment">-- ^ Float greater than</span><span>
</span><span id="line-701"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Fge"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Fge"><span class="hs-identifier hs-var">LM_CMP_Fge</span></a></span></span><span> </span><span class="hs-comment">-- ^ Float greater than or equal</span><span>
</span><span id="line-702"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Flt"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Flt"><span class="hs-identifier hs-var">LM_CMP_Flt</span></a></span></span><span> </span><span class="hs-comment">-- ^ Float less than</span><span>
</span><span id="line-703"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_CMP_Fle"><span class="annot"><a href="GHC.Llvm.Types.html#LM_CMP_Fle"><span class="hs-identifier hs-var">LM_CMP_Fle</span></a></span></span><span> </span><span class="hs-comment">-- ^ Float less than or equal</span><span>
</span><span id="line-704"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005383"><span id="local-6989586621681005385"><span class="annot"><span class="annottext">LlvmCmpOp -&gt; LlvmCmpOp -&gt; Bool
(LlvmCmpOp -&gt; LlvmCmpOp -&gt; Bool)
-&gt; (LlvmCmpOp -&gt; LlvmCmpOp -&gt; Bool) -&gt; Eq LlvmCmpOp
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmCmpOp -&gt; LlvmCmpOp -&gt; Bool
$c/= :: LlvmCmpOp -&gt; LlvmCmpOp -&gt; Bool
== :: LlvmCmpOp -&gt; LlvmCmpOp -&gt; Bool
$c== :: LlvmCmpOp -&gt; LlvmCmpOp -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-705"></span><span>
</span><span id="line-706"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621681005380"><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmCmpOp"><span class="hs-identifier hs-type">LlvmCmpOp</span></a></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-707"></span><span>  </span><span id="local-6989586621681005379"><span class="annot"><span class="annottext">ppr :: LlvmCmpOp -&gt; SDoc
</span><a href="#local-6989586621681005379"><span class="hs-identifier hs-var hs-var hs-var hs-var">ppr</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Eq"><span class="hs-identifier hs-var">LM_CMP_Eq</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;eq&quot;</span></span><span>
</span><span id="line-708"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Ne"><span class="hs-identifier hs-var">LM_CMP_Ne</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ne&quot;</span></span><span>
</span><span id="line-709"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Ugt"><span class="hs-identifier hs-var">LM_CMP_Ugt</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ugt&quot;</span></span><span>
</span><span id="line-710"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Uge"><span class="hs-identifier hs-var">LM_CMP_Uge</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;uge&quot;</span></span><span>
</span><span id="line-711"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Ult"><span class="hs-identifier hs-var">LM_CMP_Ult</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ult&quot;</span></span><span>
</span><span id="line-712"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Ule"><span class="hs-identifier hs-var">LM_CMP_Ule</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ule&quot;</span></span><span>
</span><span id="line-713"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Sgt"><span class="hs-identifier hs-var">LM_CMP_Sgt</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;sgt&quot;</span></span><span>
</span><span id="line-714"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Sge"><span class="hs-identifier hs-var">LM_CMP_Sge</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;sge&quot;</span></span><span>
</span><span id="line-715"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Slt"><span class="hs-identifier hs-var">LM_CMP_Slt</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;slt&quot;</span></span><span>
</span><span id="line-716"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Sle"><span class="hs-identifier hs-var">LM_CMP_Sle</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;sle&quot;</span></span><span>
</span><span id="line-717"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Feq"><span class="hs-identifier hs-var">LM_CMP_Feq</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;oeq&quot;</span></span><span>
</span><span id="line-718"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Fne"><span class="hs-identifier hs-var">LM_CMP_Fne</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;une&quot;</span></span><span>
</span><span id="line-719"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Fgt"><span class="hs-identifier hs-var">LM_CMP_Fgt</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ogt&quot;</span></span><span>
</span><span id="line-720"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Fge"><span class="hs-identifier hs-var">LM_CMP_Fge</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;oge&quot;</span></span><span>
</span><span id="line-721"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Flt"><span class="hs-identifier hs-var">LM_CMP_Flt</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;olt&quot;</span></span><span>
</span><span id="line-722"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCmpOp
</span><a href="GHC.Llvm.Types.html#LM_CMP_Fle"><span class="hs-identifier hs-var">LM_CMP_Fle</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ole&quot;</span></span><span>
</span><span id="line-723"></span><span>
</span><span id="line-724"></span><span>
</span><span id="line-725"></span><span class="hs-comment">-- | Llvm cast operations.</span><span>
</span><span id="line-726"></span><span class="hs-keyword">data</span><span> </span><span id="LlvmCastOp"><span class="annot"><a href="GHC.Llvm.Types.html#LlvmCastOp"><span class="hs-identifier hs-var">LlvmCastOp</span></a></span></span><span>
</span><span id="line-727"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span id="LM_Trunc"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Trunc"><span class="hs-identifier hs-var">LM_Trunc</span></a></span></span><span>    </span><span class="hs-comment">-- ^ Integer truncate</span><span>
</span><span id="line-728"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Zext"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Zext"><span class="hs-identifier hs-var">LM_Zext</span></a></span></span><span>     </span><span class="hs-comment">-- ^ Integer extend (zero fill)</span><span>
</span><span id="line-729"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Sext"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Sext"><span class="hs-identifier hs-var">LM_Sext</span></a></span></span><span>     </span><span class="hs-comment">-- ^ Integer extend (sign fill)</span><span>
</span><span id="line-730"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Fptrunc"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Fptrunc"><span class="hs-identifier hs-var">LM_Fptrunc</span></a></span></span><span>  </span><span class="hs-comment">-- ^ Float truncate</span><span>
</span><span id="line-731"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Fpext"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Fpext"><span class="hs-identifier hs-var">LM_Fpext</span></a></span></span><span>    </span><span class="hs-comment">-- ^ Float extend</span><span>
</span><span id="line-732"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Fptoui"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Fptoui"><span class="hs-identifier hs-var">LM_Fptoui</span></a></span></span><span>   </span><span class="hs-comment">-- ^ Float to unsigned Integer</span><span>
</span><span id="line-733"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Fptosi"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Fptosi"><span class="hs-identifier hs-var">LM_Fptosi</span></a></span></span><span>   </span><span class="hs-comment">-- ^ Float to signed Integer</span><span>
</span><span id="line-734"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Uitofp"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Uitofp"><span class="hs-identifier hs-var">LM_Uitofp</span></a></span></span><span>   </span><span class="hs-comment">-- ^ Unsigned Integer to Float</span><span>
</span><span id="line-735"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Sitofp"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Sitofp"><span class="hs-identifier hs-var">LM_Sitofp</span></a></span></span><span>   </span><span class="hs-comment">-- ^ Signed Int to Float</span><span>
</span><span id="line-736"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Ptrtoint"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Ptrtoint"><span class="hs-identifier hs-var">LM_Ptrtoint</span></a></span></span><span> </span><span class="hs-comment">-- ^ Pointer to Integer</span><span>
</span><span id="line-737"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Inttoptr"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Inttoptr"><span class="hs-identifier hs-var">LM_Inttoptr</span></a></span></span><span> </span><span class="hs-comment">-- ^ Integer to Pointer</span><span>
</span><span id="line-738"></span><span>  </span><span class="hs-glyph">|</span><span> </span><span id="LM_Bitcast"><span class="annot"><a href="GHC.Llvm.Types.html#LM_Bitcast"><span class="hs-identifier hs-var">LM_Bitcast</span></a></span></span><span>  </span><span class="hs-comment">-- ^ Cast between types where no bit manipulation is needed</span><span>
</span><span id="line-739"></span><span>  </span><span class="hs-keyword">deriving</span><span> </span><span class="hs-special">(</span><span id="local-6989586621681005363"><span id="local-6989586621681005365"><span class="annot"><span class="annottext">LlvmCastOp -&gt; LlvmCastOp -&gt; Bool
(LlvmCastOp -&gt; LlvmCastOp -&gt; Bool)
-&gt; (LlvmCastOp -&gt; LlvmCastOp -&gt; Bool) -&gt; Eq LlvmCastOp
forall a. (a -&gt; a -&gt; Bool) -&gt; (a -&gt; a -&gt; Bool) -&gt; Eq a
/= :: LlvmCastOp -&gt; LlvmCastOp -&gt; Bool
$c/= :: LlvmCastOp -&gt; LlvmCastOp -&gt; Bool
== :: LlvmCastOp -&gt; LlvmCastOp -&gt; Bool
$c== :: LlvmCastOp -&gt; LlvmCastOp -&gt; Bool
</span><span class="hs-identifier hs-var hs-var hs-var hs-var hs-var hs-var">Eq</span></span></span></span><span class="hs-special">)</span><span>
</span><span id="line-740"></span><span>
</span><span id="line-741"></span><span class="hs-keyword">instance</span><span> </span><span id="local-6989586621681005360"><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#LlvmCastOp"><span class="hs-identifier hs-type">LlvmCastOp</span></a></span></span><span> </span><span class="hs-keyword">where</span><span>
</span><span id="line-742"></span><span>  </span><span id="local-6989586621681005359"><span class="annot"><span class="annottext">ppr :: LlvmCastOp -&gt; SDoc
</span><a href="#local-6989586621681005359"><span class="hs-identifier hs-var hs-var hs-var hs-var">ppr</span></a></span></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Trunc"><span class="hs-identifier hs-var">LM_Trunc</span></a></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;trunc&quot;</span></span><span>
</span><span id="line-743"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Zext"><span class="hs-identifier hs-var">LM_Zext</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;zext&quot;</span></span><span>
</span><span id="line-744"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Sext"><span class="hs-identifier hs-var">LM_Sext</span></a></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;sext&quot;</span></span><span>
</span><span id="line-745"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Fptrunc"><span class="hs-identifier hs-var">LM_Fptrunc</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;fptrunc&quot;</span></span><span>
</span><span id="line-746"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Fpext"><span class="hs-identifier hs-var">LM_Fpext</span></a></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;fpext&quot;</span></span><span>
</span><span id="line-747"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Fptoui"><span class="hs-identifier hs-var">LM_Fptoui</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;fptoui&quot;</span></span><span>
</span><span id="line-748"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Fptosi"><span class="hs-identifier hs-var">LM_Fptosi</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;fptosi&quot;</span></span><span>
</span><span id="line-749"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Uitofp"><span class="hs-identifier hs-var">LM_Uitofp</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;uitofp&quot;</span></span><span>
</span><span id="line-750"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Sitofp"><span class="hs-identifier hs-var">LM_Sitofp</span></a></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;sitofp&quot;</span></span><span>
</span><span id="line-751"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Ptrtoint"><span class="hs-identifier hs-var">LM_Ptrtoint</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ptrtoint&quot;</span></span><span>
</span><span id="line-752"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Inttoptr"><span class="hs-identifier hs-var">LM_Inttoptr</span></a></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;inttoptr&quot;</span></span><span>
</span><span id="line-753"></span><span>  </span><span class="annot"><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">LlvmCastOp
</span><a href="GHC.Llvm.Types.html#LM_Bitcast"><span class="hs-identifier hs-var">LM_Bitcast</span></a></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;bitcast&quot;</span></span><span>
</span><span id="line-754"></span><span>
</span><span id="line-755"></span><span>
</span><span id="line-756"></span><span class="hs-comment">-- -----------------------------------------------------------------------------</span><span>
</span><span id="line-757"></span><span class="hs-comment">-- * Floating point conversion</span><span>
</span><span id="line-758"></span><span class="hs-comment">--</span><span>
</span><span id="line-759"></span><span>
</span><span id="line-760"></span><span class="hs-comment">-- | Convert a Haskell Double to an LLVM hex encoded floating point form. In</span><span>
</span><span id="line-761"></span><span class="hs-comment">-- Llvm float literals can be printed in a big-endian hexadecimal format,</span><span>
</span><span id="line-762"></span><span class="hs-comment">-- regardless of underlying architecture.</span><span>
</span><span id="line-763"></span><span class="hs-comment">--</span><span>
</span><span id="line-764"></span><span class="hs-comment">-- See Note [LLVM Float Types].</span><span>
</span><span id="line-765"></span><span class="annot"><a href="GHC.Llvm.Types.html#ppDouble"><span class="hs-identifier hs-type">ppDouble</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../ghc-boot/src/GHC.Platform.html#Platform"><span class="hs-identifier hs-type">Platform</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Double</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Utils.Outputable.html#SDoc"><span class="hs-identifier hs-type">SDoc</span></a></span><span>
</span><span id="line-766"></span><span id="ppDouble"><span class="annot"><span class="annottext">ppDouble :: Platform -&gt; Double -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppDouble"><span class="hs-identifier hs-var hs-var">ppDouble</span></a></span></span><span> </span><span id="local-6989586621681005357"><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005357"><span class="hs-identifier hs-var">platform</span></a></span></span><span> </span><span id="local-6989586621681005356"><span class="annot"><span class="annottext">Double
</span><a href="#local-6989586621681005356"><span class="hs-identifier hs-var">d</span></a></span></span><span>
</span><span id="line-767"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">let</span><span> </span><span id="local-6989586621681005355"><span class="annot"><span class="annottext">bs :: [Int]
</span><a href="#local-6989586621681005355"><span class="hs-identifier hs-var hs-var">bs</span></a></span></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Double -&gt; [Int]
</span><a href="GHC.CmmToAsm.Ppr.html#doubleToBytes"><span class="hs-identifier hs-var">doubleToBytes</span></a></span><span> </span><span class="annot"><span class="annottext">Double
</span><a href="#local-6989586621681005356"><span class="hs-identifier hs-var">d</span></a></span><span>
</span><span id="line-768"></span><span>        </span><span id="local-6989586621681005345"><span class="annot"><span class="annottext">hex :: a -&gt; String
</span><a href="#local-6989586621681005345"><span class="hs-identifier hs-var hs-var">hex</span></a></span></span><span> </span><span id="local-6989586621681005344"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681005344"><span class="hs-identifier hs-var">d'</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">a -&gt; ShowS
forall a. (Integral a, Show a) =&gt; a -&gt; ShowS
</span><a href="../../base/src/Numeric.html#showHex"><span class="hs-identifier hs-var">showHex</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621681005344"><span class="hs-identifier hs-var">d'</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;&quot;</span></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-769"></span><span>            </span><span class="hs-special">[</span><span class="hs-special">]</span><span>    </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">ShowS
forall a. HasCallStack =&gt; String -&gt; a
</span><a href="../../base/src/GHC.Err.html#error"><span class="hs-identifier hs-var">error</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ppDouble: too few hex digits for float&quot;</span></span><span>
</span><span id="line-770"></span><span>            </span><span class="hs-special">[</span><span id="local-6989586621681005342"><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621681005342"><span class="hs-identifier hs-var">x</span></a></span></span><span class="hs-special">]</span><span>   </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">Char
</span><span class="hs-char">'0'</span></span><span class="hs-special">,</span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621681005342"><span class="hs-identifier hs-var">x</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-771"></span><span>            </span><span class="hs-special">[</span><span id="local-6989586621681005341"><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621681005341"><span class="hs-identifier hs-var">x</span></a></span></span><span class="hs-special">,</span><span id="local-6989586621681005340"><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621681005340"><span class="hs-identifier hs-var">y</span></a></span></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621681005341"><span class="hs-identifier hs-var">x</span></a></span><span class="hs-special">,</span><span class="annot"><span class="annottext">Char
</span><a href="#local-6989586621681005340"><span class="hs-identifier hs-var">y</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-772"></span><span>            </span><span class="annot"><span class="annottext">String
</span><span class="hs-identifier">_</span></span><span>     </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">ShowS
forall a. HasCallStack =&gt; String -&gt; a
</span><a href="../../base/src/GHC.Err.html#error"><span class="hs-identifier hs-var">error</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;ppDouble: too many hex digits for float&quot;</span></span><span>
</span><span id="line-773"></span><span>
</span><span id="line-774"></span><span>        </span><span id="local-6989586621681005339"><span class="annot"><span class="annottext">fixEndian :: [a] -&gt; [a]
</span><a href="#local-6989586621681005339"><span class="hs-identifier hs-var hs-var">fixEndian</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-keyword">case</span><span> </span><span class="annot"><span class="annottext">Platform -&gt; ByteOrder
</span><a href="../../ghc-boot/src/GHC.Platform.html#platformByteOrder"><span class="hs-identifier hs-var hs-var">platformByteOrder</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005357"><span class="hs-identifier hs-var">platform</span></a></span><span> </span><span class="hs-keyword">of</span><span>
</span><span id="line-775"></span><span>            </span><span class="annot"><span class="annottext">ByteOrder
</span><a href="../../base/src/GHC.ByteOrder.html#BigEndian"><span class="hs-identifier hs-var">BigEndian</span></a></span><span>    </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">[a] -&gt; [a]
forall a. a -&gt; a
</span><a href="../../base/src/GHC.Base.html#id"><span class="hs-identifier hs-var">id</span></a></span><span>
</span><span id="line-776"></span><span>            </span><span class="annot"><span class="annottext">ByteOrder
</span><a href="../../base/src/GHC.ByteOrder.html#LittleEndian"><span class="hs-identifier hs-var">LittleEndian</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="annottext">[a] -&gt; [a]
forall a. [a] -&gt; [a]
</span><a href="../../base/src/GHC.List.html#reverse"><span class="hs-identifier hs-var">reverse</span></a></span><span>
</span><span id="line-777"></span><span>        </span><span id="local-6989586621681005329"><span class="annot"><span class="annottext">str :: String
</span><a href="#local-6989586621681005329"><span class="hs-identifier hs-var hs-var">str</span></a></span></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Char -&gt; Char) -&gt; ShowS
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">Char -&gt; Char
</span><a href="../../base/src/GHC.Unicode.html#toUpper"><span class="hs-identifier hs-var">toUpper</span></a></span><span> </span><span class="annot"><span class="annottext">ShowS -&gt; ShowS
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">[String] -&gt; String
forall (t :: * -&gt; *) a. Foldable t =&gt; t [a] -&gt; [a]
</span><a href="../../base/src/Data.Foldable.html#concat"><span class="hs-identifier hs-var">concat</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; String) -&gt; [String] -&gt; String
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">[String] -&gt; [String]
forall a. [a] -&gt; [a]
</span><a href="#local-6989586621681005339"><span class="hs-identifier hs-var">fixEndian</span></a></span><span> </span><span class="annot"><span class="annottext">([String] -&gt; [String]) -&gt; [String] -&gt; [String]
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">(Int -&gt; String) -&gt; [Int] -&gt; [String]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">Int -&gt; String
forall {a}. (Integral a, Show a) =&gt; a -&gt; String
</span><a href="#local-6989586621681005345"><span class="hs-identifier hs-var">hex</span></a></span><span> </span><span class="annot"><span class="annottext">[Int]
</span><a href="#local-6989586621681005355"><span class="hs-identifier hs-var">bs</span></a></span><span>
</span><span id="line-778"></span><span>    </span><span class="hs-keyword">in</span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;0x&quot;</span></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; SDoc -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#%3C%3E"><span class="hs-operator hs-var">&lt;&gt;</span></a></span><span> </span><span class="annot"><span class="annottext">String -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#text"><span class="hs-identifier hs-var">text</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><a href="#local-6989586621681005329"><span class="hs-identifier hs-var">str</span></a></span><span>
</span><span id="line-779"></span><span>
</span><span id="line-780"></span><span class="hs-comment">-- Note [LLVM Float Types]</span><span>
</span><span id="line-781"></span><span class="hs-comment">-- ~~~~~~~~~~~~~~~~~~~~~~~</span><span>
</span><span id="line-782"></span><span class="hs-comment">-- We use 'ppDouble' for both printing Float and Double floating point types. This is</span><span>
</span><span id="line-783"></span><span class="hs-comment">-- as LLVM expects all floating point constants (single &amp; double) to be in IEEE</span><span>
</span><span id="line-784"></span><span class="hs-comment">-- 754 Double precision format. However, for single precision numbers (Float)</span><span>
</span><span id="line-785"></span><span class="hs-comment">-- they should be *representable* in IEEE 754 Single precision format. So the</span><span>
</span><span id="line-786"></span><span class="hs-comment">-- easiest way to do this is to narrow and widen again.</span><span>
</span><span id="line-787"></span><span class="hs-comment">-- (i.e., Double -&gt; Float -&gt; Double). We must be careful doing this that GHC</span><span>
</span><span id="line-788"></span><span class="hs-comment">-- doesn't optimize that away.</span><span>
</span><span id="line-789"></span><span>
</span><span id="line-790"></span><span class="hs-comment">-- Note [narrowFp &amp; widenFp]</span><span>
</span><span id="line-791"></span><span class="hs-comment">-- ~~~~~~~~~~~~~~~~~~~~~~~~~</span><span>
</span><span id="line-792"></span><span class="hs-comment">-- NOTE: we use float2Double &amp; co directly as GHC likes to optimize away</span><span>
</span><span id="line-793"></span><span class="hs-comment">-- successive calls of 'realToFrac', defeating the narrowing. (Bug #7600).</span><span>
</span><span id="line-794"></span><span class="hs-comment">-- 'realToFrac' has inconsistent behaviour with optimisation as well that can</span><span>
</span><span id="line-795"></span><span class="hs-comment">-- also cause issues, these methods don't.</span><span>
</span><span id="line-796"></span><span>
</span><span id="line-797"></span><span class="annot"><a href="GHC.Llvm.Types.html#narrowFp"><span class="hs-identifier hs-type">narrowFp</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Double</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Float</span></span><span>
</span><span id="line-798"></span><span class="hs-pragma">{-# NOINLINE</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#narrowFp"><span class="hs-pragma hs-type">narrowFp</span></a></span><span> </span><span class="hs-pragma">#-}</span><span>
</span><span id="line-799"></span><span id="narrowFp"><span class="annot"><span class="annottext">narrowFp :: Double -&gt; Float
</span><a href="GHC.Llvm.Types.html#narrowFp"><span class="hs-identifier hs-var hs-var">narrowFp</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Double -&gt; Float
</span><a href="../../base/src/GHC.Float.html#double2Float"><span class="hs-identifier hs-var">double2Float</span></a></span><span>
</span><span id="line-800"></span><span>
</span><span id="line-801"></span><span class="annot"><a href="GHC.Llvm.Types.html#widenFp"><span class="hs-identifier hs-type">widenFp</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Float</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Double</span></span><span>
</span><span id="line-802"></span><span class="hs-pragma">{-# NOINLINE</span><span> </span><span class="annot"><a href="GHC.Llvm.Types.html#widenFp"><span class="hs-pragma hs-type">widenFp</span></a></span><span> </span><span class="hs-pragma">#-}</span><span>
</span><span id="line-803"></span><span id="widenFp"><span class="annot"><span class="annottext">widenFp :: Float -&gt; Double
</span><a href="GHC.Llvm.Types.html#widenFp"><span class="hs-identifier hs-var hs-var">widenFp</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Float -&gt; Double
</span><a href="../../base/src/GHC.Float.html#float2Double"><span class="hs-identifier hs-var">float2Double</span></a></span><span>
</span><span id="line-804"></span><span>
</span><span id="line-805"></span><span class="annot"><a href="GHC.Llvm.Types.html#ppFloat"><span class="hs-identifier hs-type">ppFloat</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="../../ghc-boot/src/GHC.Platform.html#Platform"><span class="hs-identifier hs-type">Platform</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Float</span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Utils.Outputable.html#SDoc"><span class="hs-identifier hs-type">SDoc</span></a></span><span>
</span><span id="line-806"></span><span id="ppFloat"><span class="annot"><span class="annottext">ppFloat :: Platform -&gt; Float -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppFloat"><span class="hs-identifier hs-var hs-var">ppFloat</span></a></span></span><span> </span><span id="local-6989586621681005321"><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005321"><span class="hs-identifier hs-var">platform</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Platform -&gt; Double -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppDouble"><span class="hs-identifier hs-var">ppDouble</span></a></span><span> </span><span class="annot"><span class="annottext">Platform
</span><a href="#local-6989586621681005321"><span class="hs-identifier hs-var">platform</span></a></span><span> </span><span class="annot"><span class="annottext">(Double -&gt; SDoc) -&gt; (Float -&gt; Double) -&gt; Float -&gt; SDoc
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">Float -&gt; Double
</span><a href="GHC.Llvm.Types.html#widenFp"><span class="hs-identifier hs-var">widenFp</span></a></span><span>
</span><span id="line-807"></span><span>
</span><span id="line-808"></span><span>
</span><span id="line-809"></span><span class="hs-comment">--------------------------------------------------------------------------------</span><span>
</span><span id="line-810"></span><span class="hs-comment">-- * Misc functions</span><span>
</span><span id="line-811"></span><span class="hs-comment">--------------------------------------------------------------------------------</span><span>
</span><span id="line-812"></span><span>
</span><span id="line-813"></span><span id="local-6989586621681005950"><span class="annot"><a href="GHC.Llvm.Types.html#ppCommaJoin"><span class="hs-identifier hs-type">ppCommaJoin</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="#local-6989586621681005950"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="#local-6989586621681005950"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Utils.Outputable.html#SDoc"><span class="hs-identifier hs-type">SDoc</span></a></span></span><span>
</span><span id="line-814"></span><span id="ppCommaJoin"><span class="annot"><span class="annottext">ppCommaJoin :: forall a. Outputable a =&gt; [a] -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppCommaJoin"><span class="hs-identifier hs-var hs-var">ppCommaJoin</span></a></span></span><span> </span><span id="local-6989586621681005317"><span class="annot"><span class="annottext">[a]
</span><a href="#local-6989586621681005317"><span class="hs-identifier hs-var">strs</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[SDoc] -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#hsep"><span class="hs-identifier hs-var">hsep</span></a></span><span> </span><span class="annot"><span class="annottext">([SDoc] -&gt; SDoc) -&gt; [SDoc] -&gt; SDoc
forall a b. (a -&gt; b) -&gt; a -&gt; b
</span><a href="../../base/src/GHC.Base.html#%24"><span class="hs-operator hs-var">$</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc -&gt; [SDoc] -&gt; [SDoc]
</span><a href="GHC.Utils.Outputable.html#punctuate"><span class="hs-identifier hs-var">punctuate</span></a></span><span> </span><span class="annot"><span class="annottext">SDoc
</span><a href="GHC.Utils.Outputable.html#comma"><span class="hs-identifier hs-var">comma</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(a -&gt; SDoc) -&gt; [a] -&gt; [SDoc]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">[a]
</span><a href="#local-6989586621681005317"><span class="hs-identifier hs-var">strs</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-815"></span><span>
</span><span id="line-816"></span><span id="local-6989586621681005313"><span class="annot"><a href="GHC.Llvm.Types.html#ppSpaceJoin"><span class="hs-identifier hs-type">ppSpaceJoin</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="GHC.Utils.Outputable.html#Outputable"><span class="hs-identifier hs-type">Outputable</span></a></span><span> </span><span class="annot"><a href="#local-6989586621681005313"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="#local-6989586621681005313"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Utils.Outputable.html#SDoc"><span class="hs-identifier hs-type">SDoc</span></a></span></span><span>
</span><span id="line-817"></span><span id="ppSpaceJoin"><span class="annot"><span class="annottext">ppSpaceJoin :: forall a. Outputable a =&gt; [a] -&gt; SDoc
</span><a href="GHC.Llvm.Types.html#ppSpaceJoin"><span class="hs-identifier hs-var hs-var">ppSpaceJoin</span></a></span></span><span> </span><span id="local-6989586621681005309"><span class="annot"><span class="annottext">[a]
</span><a href="#local-6989586621681005309"><span class="hs-identifier hs-var">strs</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[SDoc] -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#hsep"><span class="hs-identifier hs-var">hsep</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(a -&gt; SDoc) -&gt; [a] -&gt; [SDoc]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; SDoc
forall a. Outputable a =&gt; a -&gt; SDoc
</span><a href="GHC.Utils.Outputable.html#ppr"><span class="hs-identifier hs-var">ppr</span></a></span><span> </span><span class="annot"><span class="annottext">[a]
</span><a href="#local-6989586621681005309"><span class="hs-identifier hs-var">strs</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-818"></span></pre></body></html>